You should note that Wiki is out of date info. Nane was removed for GetShapshifeFormInfo. It is currently
icon, isActive, isCastable, sID = GetShapeshiftFormInfo...
You would need to change the 3 to 2 to detect the active form of the player..
API GetShapeshiftFormInfo
Retrieves information about an available shapeshift form or similar ability.
icon, active, castable, spellID = GetShapeshiftFormInfo(index);
Arguments
index
Number - index, ascending from 1 to GetNumShapeshiftForms()
Returns
icon
String - Path to icon texture
active
Flag - 1 if this shapeshift is currently active, nil otherwise
castable
Flag - 1 if this shapeshift form may be entered, nil otherwise
spellID
Number - ID of the spell that activates this ability
Notes
As well as druid shapeshifting, warrior stances, paladin auras, hunter aspects, death knight presences, and shadowform use this API.
Originally Posted by Zam89
Thanks, I will try this.
At the Moment I use this:
Code:
local s = nil
for i = 1, GetNumShapeshiftForms() do
if select(3, GetShapeshiftFormInfo(i)) then
s = i
end
end
And check if i is 3 because on the site https://wowwiki.fandom.com/wiki/API_...eshiftFormInfo it Said that CAT is 3 and on your Site it should be 2.
Any ideas?
|