Skip to content
everloot

Lore archive · Warcraft Wiki, 2023 dump

API GetTotemInfo

Last wiki revision 2022-07-22

Returns info for the specified totem. haveTotem, totemName, startTime, duration, icon = GetTotemInfo(index)

  • index: - index of the totem (Fire = 1 Earth = 2 Water = 3 Air = 4)
  • haveTotem:returns true if you have the totem reagent in your bag.
  • totemName:returns the name of the currently active totem. If there is no active totem for this slot, this value will apparently be an empty string ("") instead of nil.
  • startTime:returns the GetTime value of when the totem started.
  • duration:returns the duration (in seconds) of the currently active totem.
  • icon:returns the path to the icon of the specified totem
  • Example

Displays the duration of all active totems

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

  • GetTotemTimeLeft(slot): global function returns active time remaining (in seconds) for a totem in a given slot.
  • The MAX_TOTEMS constant can be used to determine how many totems are available to iterate over.

Source

https://warcraft.wiki.gg/wiki/API_GetTotemInfo · retrieved 2023-11-13 · CC BY-SA 4.0

Converted from wikitext with templates, tables and images removed, so some sentences may be missing values.

This archive predates WoW: Forever. For collected gameplay facts see the Forever database. Search the archive.