Difference between revisions of "SendAnimationEvent - Debug"
Jump to navigation
Jump to search
imported>MoopusMaximus |
imported>MoopusMaximus |
||
(One intermediate revision by one other user not shown) | |||
Line 24: | Line 24: | ||
== Notes == | == Notes == | ||
This bypasses the check on [[ObjectReference Script|ObjectReference]] that prevents sending events to actors. If you use it to send an event to actors, you will most likely mess up the actor permanently as the internal actor data may no longer match their animation state. | *This bypasses the check on [[ObjectReference Script|ObjectReference]] that prevents sending events to actors. If you use it to send an event to actors, you will most likely mess up the actor permanently as the internal actor data may no longer match their animation state. | ||
SendAnimationEvent uses "Anim Events" under the Idle Manager, not the | *SendAnimationEvent uses "Anim Events" under the Idle Manager, not the IDs. For example, to make an actor play the animation of attacking left, you must use "AttackStartLeftHand", not "LeftHandAttack" (its ID). | ||
*Animation Event's will actually cause the actor to perform the action associated with it. For example, sending the animation event "AttackStart" will cause the reference to perform an attack. Anything in front of it '''will''' get hurt. This example is true for all animation event's. For example, sending the "DeathAnim" will actually kill the actor. | |||
== See Also == | == See Also == | ||
*[[Debug Script]] | *[[Debug Script]] | ||
*[[PlayAnimation - ObjectReference]] | *[[PlayAnimation - ObjectReference]] |
Latest revision as of 14:23, 17 April 2012
Member of: Debug Script
Sends an animation event to a reference directly.
Syntax[edit | edit source]
Function SendAnimationEvent(ObjectReference arRef, string asEventName) native global
Parameters[edit | edit source]
- arRef: The reference to send the event to.
- asEventName: The event to send.
Return Value[edit | edit source]
None
Examples[edit | edit source]
; Sends the dance event to the bard
Debug.SendAnimationEvent(BardRef, "Dance")
Notes[edit | edit source]
- This bypasses the check on ObjectReference that prevents sending events to actors. If you use it to send an event to actors, you will most likely mess up the actor permanently as the internal actor data may no longer match their animation state.
- SendAnimationEvent uses "Anim Events" under the Idle Manager, not the IDs. For example, to make an actor play the animation of attacking left, you must use "AttackStartLeftHand", not "LeftHandAttack" (its ID).
- Animation Event's will actually cause the actor to perform the action associated with it. For example, sending the animation event "AttackStart" will cause the reference to perform an attack. Anything in front of it will get hurt. This example is true for all animation event's. For example, sending the "DeathAnim" will actually kill the actor.