Difference between revisions of "EVENT TYPE TRAP TRIGGERED"

From Dragon Age Toolset Wiki
Jump to: navigation, search
 
Line 12: Line 12:
 
|location0desc=Impact location
 
|location0desc=Impact location
 
}}
 
}}
 +
 +
[[Category:Event types|TRAP_TRIGGERED]]
 +
[[Category:Trap events|TRAP_TRIGGERED]]

Latest revision as of 04:11, 4 January 2010

The documentation on this page is incomplete, obsolete, or otherwise in need of a thorough review. The current content may provide a good starting point for this, but do not rely on its accuracy when using it to design content.

Source:
script.ldf
Sent when:
sent by the engine when a placeable trap collides with something (eg. swinging log trap strikes a creature).
Sent from:
engine
Sent to:
Parameters:
  • Object 0: Target hit by trap
  • Location 0: Impact location

Usage

case EVENT_TYPE_TRAP_TRIGGERED:
{
object oTarget = GetEventObject(ev, 0); // Target hit by trap
location lImpact = GetEventLocation(ev, 0); // Impact location

// insert event-handling code here

break;
}