Recent changes Random page
GAMING
Gaming
 
StarCraft Wiki
Super Smash Wiki
Halopedia
Diablo Wiki
FFXIclopedia
Grand Theft Wiki
See more...

API GetTotemInfo

From WoWWiki

Jump to: navigation, search
Main Menu



Returns information about totems

haveTotem, totemName, startTime, duration = GetTotemInfo(1 through 4)


Parameters

Arguments

(integer)
integer
integer - index of the totem (Fire = 1 Earth = 2 Water = 3 Air = 4)

Returns

haveTotem
returns true if you have the totem reagent in your bag ([Earth Totem], [Fire Totem], [Water Totem], [Air Totem]).
totemName
returns the name of the currently active totem.
startTime
returns the GetTime() value of when the totem started.
duration
returns the duraiton (in seconds) of the currently active totem.



Example

Displays the duration of all active totems

for index=1,4 do
  local arg1, totemName, startTime, duration = GetTotemInfo(index)
  local est_dur = round(startTime+duration-GetTime() )
  DEFAULT_CHAT_FRAME:AddMessage(totemName .. "  " .. est_dur)  
end

Details

GetTotemTimeLeft(slot): global function returns active time remaining (in seconds) for a totem in a given slot.

Rate this article:
Share this article: