Trigger impact

From Valve Developer Community

This Brush-based Entity is available in all Source Games.

Table of contents

Entity Description

A trigger volume that can be told to push all physics objects that are inside of it in the direction specified by this trigger's angles. Also outputs the force at the time of impact for anyone else that wants to use it.

In code it is represented by class CTriggerImpact (http://doxygen.page.needed/class_c_trigger_impact.html), defined in triggers.cpp (http://doxygen.page.needed/triggers_8cpp-source.html).

Keyvalues

Defines the name that other entities refer to this entity by.
  • hammerid [Episode Two Update]
<integer readonly> This id is used for debugging purposes in Hammer.
  • origin
<origin> The position of this entity's center in the world. Rotating entities rotate around their origin.
Pitch Yaw Roll (Y Z X)
This entity's angular orientation in the world (also used for angular effect entities).
  • Magnitude
<float> The strength of the impact. Negative values reverse the direction.
  • noise
<float> The amount of directional noise (0-1). 0 = no noise, 1 = random direction.
  • viewkick
<float> The amount to kick player's view if the player is in the trigger. Proportional to magnitude (0-1).

Inputs

  • Kill
Removes this entity from the world.
Removes this entity and all its children from the world.
  • AddOutput <string>
Evaluates a keyvalue/output on this entity. It can be potentially very dangerous, use with care.
Format: <key> <value>
Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>
Causes this entity's OnUser1-4 outputs to be fired. See User Inputs and Outputs.
  • Impact <float>
Fire the impact, pushing all entities within the volume.
  • SetMagnitude <float>
Set the magnitude of the impact.

Outputs

Fired in response to FireUser1-4 inputs. See User Inputs and Outputs.
!activator = activator
  • ImpactForce <string>
Fired after an impact. The parameter passed along is the force of the impact that was generated.