Difference between revisions of "EquipSpell - Actor"
Jump to navigation
Jump to search
imported>Rhavlovick m (1 revision: Clobber re-import by Henning) |
imported>JustinOther |
||
Line 32: | Line 32: | ||
Bob.EquipSpell(WerewolfChange, 2) | Bob.EquipSpell(WerewolfChange, 2) | ||
</source> | </source> | ||
== Notes == | |||
*If the calling actor does not have akSpell, it will be given to them. | |||
<source lang="papyrus">Game.GetPlayer().EquipSpell(BoundBow, 1) ; Gives BoundBow to player unless they've already got it</source> | |||
== See Also == | == See Also == |
Revision as of 10:08, 7 April 2012
Member of: Actor Script
Forces the actor to equip the specified spell in the specified source.
Syntax
Function EquipSpell(Spell akSpell, int aiSource) native
Parameters
- akSpell: The spell to force the actor to equip.
- aiSource: The source to equip the spell into.
- One of the following values is acceptable:
- 0: Left hand
- 1: Right hand
- 2: Voice (use this for Powers)
- aiSource is required, but it will be overridden by the Spell's Equip Slot if it is set to anything other than BothHands in the editor.
- One of the following values is acceptable:
Return Value
None.
Examples
; Forces bob to equip ward into his right hand
Bob.EquipSpell(WardProperty, 1)
; Equip the Beast Form power. Note that WerewolfChange's Equip Slot must be set to Voice.
Bob.EquipSpell(WerewolfChange, 2)
Notes
- If the calling actor does not have akSpell, it will be given to them.
Game.GetPlayer().EquipSpell(BoundBow, 1) ; Gives BoundBow to player unless they've already got it