Logic collision pair: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Which kinds of names are accepted, and when.)
(-added class hierarchy, cleanup)
Line 1: Line 1:
{{CD|CLogicCollisionPair|file1=logicentities.cpp}}
{{base point|logic_collision_pair}}  
{{base point|logic_collision_pair}}  


==Entity description==
It can be used to enable/disable [[VPhysics]] collisions between two target entities.
It can be used to enable/disable [[VPhysics]] collisions between two target entities.


== Keyvalues ==
== Keyvalues ==
{{KV|Attachment 1|target_destination|The first entity.}}
{{KV|Attachment 1|intn=attach1|target_destination|The first entity.}}
{{KV|Attachment 2|target_destination|The second entity.}}
{{KV|Attachment 2|intn=attach1|target_destination|The second entity.}}
{{Note| These targetnames are evaluated at enable time. !activator and !caller are not accepted.}}
{{Note|These targetnames are evaluated at enable time. !activator and !caller are not accepted.}}
{{KV|Start with collisions disabled|boolean|If '''Yes''', starts with collisions between the pair disabled.  If '''No''', starts with collisions between the pair enabled.}}
{{KV|Start with collisions disabled|intn=startdisabled|boolean|If '''Yes''', starts with collisions between the pair disabled.  If '''No''', starts with collisions between the pair enabled.}}
{{KV Targetname}}
{{KV Targetname}}


Line 14: Line 14:
{{IO|EnableCollisions|Enable collisions between the first and second entity.}}
{{IO|EnableCollisions|Enable collisions between the first and second entity.}}
{{IO|DisableCollisions|Disable collisions between the first and second entity.}}
{{IO|DisableCollisions|Disable collisions between the first and second entity.}}
{{I Targetname}}
== Outputs ==
{{O Targetname}}

Revision as of 15:52, 6 November 2022

C++ Class hierarchy
CLogicCollisionPair
CLogicalEntity
CServerOnlyEntity
CBaseEntity
C++ logicentities.cpp

Template:Base point

It can be used to enable/disable VPhysics collisions between two target entities.

Keyvalues

Attachment 1 (attach1) <targetname>
The first entity.
Attachment 2 (attach1) <targetname>
The second entity.
Note.pngNote:These targetnames are evaluated at enable time. !activator and !caller are not accepted.
Start with collisions disabled (startdisabled) <boolean>
If Yes, starts with collisions between the pair disabled. If No, starts with collisions between the pair enabled.
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

Inputs

EnableCollisions
Enable collisions between the first and second entity.
DisableCollisions
Disable collisions between the first and second entity.