WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   Carbonite Archive (https://www.wowinterface.com/forums/forumdisplay.php?f=158)
-   -   API for other addons to add points to the Carbonite map? (https://www.wowinterface.com/forums/showthread.php?t=33673)

Zasurus 07-02-10 06:38 PM

API for other addons to add points to the Carbonite map?
 
Hi,
Is it posible to get a very small (3-6 lines) section of Carbonite's code changed to better allow 3rd party addon's to add and use icon's on the map?

Let me explain my current situation. I currently have a few addons that put icons on the Carbonite map by using the functions Nx.Map:GeM, IIT(), SITA(), SITAS(), Nx.MNTI1, AIP(), SIT() among others and it has taken me quite some time to work out how to do this (as the original API's created for the task of addon intergration have since become obsolete).

These DO allow me to add points to the carbonite maps and that is GREAT! :) BUT I want to be able to specifi the colour of these points but even though SOME of the code is there to allow this it doesn't work as the colour of the icon's are hard coded to be the standard colour. :(

What I would like to surgest is modifying lines 24077-24079 in Carbonite.lua. This is currently:
Code:

if v.Alp then
f.tex:SetVertexColor(1,1,1,v.Alp)
end

and I think it should be:
Code:

local r,g,b = 1,1,1
if (ico.Col1) then
        r,g,b = c2r1(ico.Col1)
end;
if v.Alp then
        f.tex:SetVertexColor(r,g,b,v.Alp)
end

Even though this is a tiny change it would allow me to change the colour of any of the points I add onto the map therefore allowing me to crete 1 grayscale icon and change it to ANY colour making my addon much more versitile.


Hope this isn't to much trouble...


Thanks for such a great addon!

Zas

P.S. If someone could point me towards a wiki/knowledge base for Carbonite that I can add to I will write a tutorial on how to simply add icons to Carbonite using it's own functions (the way it does!) and therefore enabling addon authors to create addon's that work with Carbonite! :banana:


All times are GMT -6. The time now is 12:44 PM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI