m
Move page script moved page API GetBonusBarOffset to WoW:API GetBonusBarOffset without leaving a redirect
m (internal link) |
m (Move page script moved page API GetBonusBarOffset to WoW:API GetBonusBarOffset without leaving a redirect) |
||
| (5 intermediate revisions by 5 users not shown) | |||
| Line 1: | Line 1: | ||
{{wowapi}} | {{wowapi}} | ||
Returns the current bonus action bar index. | Returns the current bonus action bar index. | ||
offset = GetBonusBarOffset() | |||
offset = GetBonusBarOffset() | |||
== Parameters == | == Parameters == | ||
Arguments: | |||
: | :none | ||
Returns: | |||
:;offset - Number : The current bonus action bar index. | :;offset - Number : The current bonus action bar index. | ||
| Line 24: | Line 20: | ||
'''Druid''' | '''Druid''' | ||
* | * Caster: 0 | ||
* Cat: 1 | |||
* Tree of Life: 2 | |||
* Bear: 3 | |||
* Moonkin: 4 | |||
'''Rogue''' | '''Rogue''' | ||
* Normal: 0 | * Normal: 0 | ||
* Stealthed: 1 | * Stealthed: 1 | ||
'''Priest''' | |||
* Normal: 0 | |||
* Shadowform: 1 | |||
'''All Characters''' | |||
* When Possessing a Target: 5 | |||
== Example == | == Example == | ||
/script ChatFrame1:AddMessage(GetBonusBarOffset()) | |||
slotID = (1 + (NUM_ACTIONBAR_PAGES + GetBonusBarOffset() - 1) * NUM_ACTIONBAR_BUTTONS) | |||
This will simply print the output of GetBonusBarOffset(). It should change as you change between your bonus bars. | |||
slotID = (1 + (NUM_ACTIONBAR_PAGES + GetBonusBarOffset() - 1) * NUM_ACTIONBAR_BUTTONS) | |||
Here, slotID will be the action slot number for the first slot of the current bonus bar. For example, for a Warrior in Defensive Stance, <tt>slotID = 85</tt>, which is correct. ([[ActionSlot]]) | |||