CTriggerPush
Jump to navigation
Jump to search
Code classes:
CTriggerPush
CBaseTrigger
(triggers)CBaseToggle
CBaseEntity
(all ents)
CTriggerPush
is a code class present in all Source games.
Classnames:
trigger_push
- It's a brush that pushes things.
Note: trigger_push
es that are compiled into entity groups are converted to the entity script_trigger_push
.
Flags[edit | edit source]
- 128: Once Only - Trigger removes itself after pushing a single object once.
- 256: Affects Ladders (only available in ) - Pushes players even when on ladders. Causes them to dismount if enough force is used.
- 4096: Correctly account for object mass and multiple component physobjs (available in all games since ) - Lighter objects will get pushed the same distance as heavier ones, and objects consisting of multiple rigid parts will have all their parts receive force, instead of only one.
Keyvalues[edit | edit source]
- Push Direction (Pitch Yaw Roll)
(pushdir)
<angle>
- Direction of force.
- Speed of Push
(speed)
<float>
- How much to push things.
- Scale force for alternate ticks
(alternateticksfix)
<float>
- If non-zero, force is multiplied by this much when the server is running with
sv_alternateticks 1
. To do: What are good values for this? Trigger on Start Touch(triggeronstarttouch)
<boolean>
(only available in )- Doesn't affect anything.
- Only Falling Players
(OnlyFallingPlayers)
<boolean>
(only available in ) - If set, players must be airborne while not pressing jump, and be falling faster than Player fall speed to get pushed. Does not affect outputs.
- Player fall speed
(FallingSpeedThreshold)
<float>
(only available in ) - If Only Falling Players is on, players must have a Z velocity below this number in order to be pushed. A value of -300 means a player must be falling faster than 300 units.
Inputs[edit | edit source]
- SetPushDirection (Not in FGD)
<angle>
(available in all games since ) - Sets Push Direction.
- SetPushSpeed (Not in FGD)
<float>
(only available in ) - Sets Speed of Push.