Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
WoW
Talk
English
Views
Read
Edit
History
More
Search
Navigation
Home
Random page
Help using wiki
Editions
for WoW
for WildStar
for Solar2D
Documentation
for WoW
for WildStar
Reference
WoW
⦁ FrameXML
⦁ AddOns
⦁ API
⦁ WoW Lua
WildStar
⦁ AddOns
⦁ API
⦁ WildStar Lua
Engine
Tools
What links here
Related changes
Special pages
Page information
Site
Recent Changes
Editing
WoW:API CastShapeshiftForm
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{wowapi}}__NOTOC__ {{protectedapi|2.0.1|For alternatives, try [[API_SecureTemplates|Secure Template]] or the new [[Conditional slash commands#/cast|/cast]].}} Casts Shapeshift on yourself. This is class dependent - not all classes have special abilities. CastShapeshiftForm(index); == Parameters == === Arguments === ;index : relates to the different forms: :;Druid :*1 = Bear/Dire Bear Form :*2 = Aquatic Form :*3 = Cat Form :*4 = Travel Form :*5 = Moonkin Form : :;Rogue :*1 = Stealth : :;Warrior :*1 = Battle Stance :*2 = Defensive Stance :*3 = Beserker Stance === Returns === :'''nil''' == Example == CastShapeshiftForm(1); === Result === Shapeshifts caster into Bear Form. == Note == Note, casting the spell again changes back to caster form. So, for instance; if (GetNumShapeshiftForms()==1) then CastShapeshiftForm(1);end; In this case, the script checks if you're in Bear/Dire Bear form, and if so, casts the spell to change you back to Caster form. It has the same restrictions as other casting spells in that the trigger event needs to involve a keystroke or mouse click. To use a particular shape in a '''macro''' and avoiding error messages, use: /script icon, name, active = GetShapeshiftFormInfo('''index''');if (active==1) then CastShapeshiftForm('''index''');end; where '''index''' is the number of the shape as given above. == Example == This Example shows how to return to your human form out of any other form. for i=1, GetNumShapeshiftForms() do _, name, active = GetShapeshiftFormInfo(i); if( active ~= nil ) then DEFAULT_CHAT_FRAME:AddMessage("SQS: leaving '"..name.."'"); CastShapeshiftForm(i) break; end end
Summary:
Please note that all contributions to AddOn Studio are considered to be released under the Creative Commons Attribution-NonCommercial-ShareAlike (see
AddOn Studio Wiki:Copyrights
for details).
Submissions must be written by you, or copied from a public domain or similar free resource (see
AddOn Studio Wiki:Copyrights
for details).
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Ambox
(
edit
)
Template:Apinav
(
edit
)
Template:Editlink
(
edit
)
Template:Protectedapi
(
edit
)
Template:Tocright
(
edit
)
Template:Wowapi
(
edit
)