This article's documentation is for anything that uses the Source engine. Click here for more information.

Trigger gravity: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
No edit summary
 
(6 intermediate revisions by 2 users not shown)
Line 4: Line 4:
{{this is a|brush entity|name=trigger_gravity}} It scales the force of [[gravity]] of players touching its volume.
{{this is a|brush entity|name=trigger_gravity}} It scales the force of [[gravity]] of players touching its volume.


The change in gravity applies until the player touches another {{code|trigger_gravity}}.
The change in gravity applies until the player touches another {{code|trigger_gravity}} (even if the player respawns in a multiplayer setting).
{{warning|This entity only affects the player's gravity. The flags only affect the generic trigger outputs.}}
{{warning|This entity only affects the player's gravity. The flags only affect the generic trigger outputs.}}


== Keyvalues ==
== Keyvalues ==
{{otherKIO|trigger}}
{{KV Targetname}}
{{KV Targetname}}
{{KV|Gravity|intn=gravity|float|Gravity multiplier. 1 is normal gravity, 0 is none. Accepts negative values and decimals.}}
{{KV|Gravity|intn=gravity|float|Gravity multiplier. 1 is normal gravity, 0 is none. Accepts negative values and decimals. Very high values (such as 100) will result in players not being able to jump more than a [[unit]].}}
:{{note|Also affects what height players can fall before receiving fall damage.}}
{{KV Trigger}}
{{KV Trigger}}



Latest revision as of 10:36, 24 November 2025

English (en)Translate (Translate)
C++ Class hierarchy
CTriggerGravity
CBaseTrigger
CBaseToggle
CBaseEntity
C++ triggers.cpp

trigger_gravity is a brush entity available in all Source Source games. It scales the force of gravity of players touching its volume.

The change in gravity applies until the player touches another trigger_gravity (even if the player respawns in a multiplayer setting).

Warning.pngWarning:This entity only affects the player's gravity. The flags only affect the generic trigger outputs.

Keyvalues

Note.pngNote:Other Keyvalues / Inputs / Outputs are same as trigger.
Name (targetname) <string>
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also: Generic Keyvalues, Inputs and Outputs available to all entities
Gravity (gravity) <float>
Gravity multiplier. 1 is normal gravity, 0 is none. Accepts negative values and decimals. Very high values (such as 100) will result in players not being able to jump more than a unit.
Note.pngNote:Also affects what height players can fall before receiving fall damage.
BaseTrigger
Filter Name (filtername) <filter>
A filter entity to test potential activators against.
Start Disabled (StartDisabled) <boolean>
Stay dormant until activated (with theEnableinput).

Inputs

EnableDisable:

Enable / Disable
Enable/disable this entity from performing its task. It might also disappear from view.

See also