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

Env physimpact: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(raw; needs cleanup)
 
m (→‎Inputs: Substituted IO templates)
 
(28 intermediate revisions by 15 users not shown)
Line 1: Line 1:
{{cleanup}}
{{LanguageBar}}
env_physimpact
{{CD|CPhysImpact|file1=physobj.cpp}}
{{this is a|point entity|name=env_physimpact}} It causes a physics impact on another entity. The direction of the impact is determined by the angles set.


An entity that will cause a physics impact on another entity.
==Keyvalues==
{{KV Targetname}}
{{KV Angles|Direction to project the impact.}}
{{KV|Magnitude|intn=magnitude|integer|Strength of the impact.}}
{{KV|Distance|intn=distance|integer|How far to project the impact (if 0 uses a default value).}}
{{KV|Point to Entity|intn=directionentityname|target_destination|If set, '''Distance''' and '''Pitch Yaw Roll''' settings are ignored and the direction and distance to the target entity will be used.}}


KEYS
==Inputs==
{{I|Impact|Trigger the impact}}


Name targetname <target_source> The name that other entities refer to this entity by.
==Flags==
 
{{fl|1|No fall-off}}
Parent parentname <target_destination> The name of this entity's parent in the movement hierarchy. Entities with parents move with their parent.
{{fl|2|Infinite Length}}
 
{{fl|4|Ignore Mass}}
Pitch Yaw Roll (Y Z X) angles <string> Direction to project the impact.
{{fl|8|Ignore Surface Normal When Applying Force{{clarify}}}}
 
Magnitude magnitude <integer> Strength of the impact.
 
Distance distance <integer> How far to project the impact (if 0 uses a default value).
 
Point to Entity directionentityname <target_destination> If set, 'Distance' and Angle settings are ignored and the direction and distance to the target entity will be used.
 
spawnflags spawnflags <flags>
 
 
INPUTS
 
Kill Removes this entity from the world.
 
KillHierarchy Removes this entity and all its children from the world.
 
AddOutput <string> Adds an entity I/O connection to this entity. Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>. Very dangerous, use with care.
 
FireUser1 Causes this entity's OnUser1 output to be fired.
 
FireUser2 Causes this entity's OnUser2 output to be fired.
 
FireUser3 Causes this entity's OnUser3 output to be fired.
 
FireUser4 Causes this entity's OnUser4 output to be fired.
 
SetParent <string> Changes the entity's parent in the movement hierarchy.
 
SetParentAttachment <string> Change this entity to attach to a specific attachment point on its parent. Entities must be parented before being sent this input. The parameter passed in should be the name of the attachment.
 
ClearParent Removes this entity from the the movement hierarchy, leaving it free to move independently.
 
Impact Trigger the impact
 
 
OUTPUTS
 
OnUser1 Fired in response to FireUser1 input.
 
OnUser2 Fired in response to FireUser2 input.
 
OnUser3 Fired in response to FireUser3 input.
 
OnUser4 Fired in response to FireUser4 input.

Latest revision as of 09:53, 21 April 2025

English (en)Translate (Translate)
C++ Class hierarchy
CPhysImpact
CPointEntity
CBaseEntity
C++ physobj.cpp

env_physimpact is a point entity available in all Source Source games. It causes a physics impact on another entity. The direction of the impact is determined by the angles set.

Keyvalues

Name (targetname) <string>[ Edit ]
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
Pitch Yaw Roll (Y Z X) (angles) <QAngle>
Direction to project the impact.
Magnitude (magnitude) <integer>
Strength of the impact.
Distance (distance) <integer>
How far to project the impact (if 0 uses a default value).
Point to Entity (directionentityname) <targetname>
If set, Distance and Pitch Yaw Roll settings are ignored and the direction and distance to the target entity will be used.

Inputs

Impact
Trigger the impact

Flags

No fall-off : [1]
Infinite Length : [2]
Ignore Mass : [4]
Ignore Surface Normal When Applying Force[Clarify] : [8]