Point proximity sensor: Difference between revisions
Jump to navigation
Jump to search
m (Changed parameters of {{this is a}} to comply with the updated version. This action was performed by a bot.) |
MyGamepedia (talk | contribs) |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{CD|CPointProximitySensor|file1=pointanglesensor.cpp}} | |||
{{this is a|point entity|name=point_proximity_sensor}} It continuously outputs the distance from itself to a target entity. | {{this is a|point entity|name=point_proximity_sensor}} It continuously outputs the distance from itself to a target entity. | ||
__NOTOC__ | __NOTOC__ | ||
== Keyvalues == | == Keyvalues == | ||
{{KV Targetname}} | {{KV Targetname}} | ||
{{KV|Target Entity Name|intn=target|target_destination|Name of the entity whose distance will be sensed.}} | {{KV|Target Entity Name|intn=target|target_destination|Name of the entity whose distance will be sensed. | ||
:{{important|Target entity must exist when this entity spawns (can be set later via ''SetTargetEntity'' input).}} | |||
}} | |||
{{KV Angles}} | {{KV Angles}} | ||
{{KV EnableDisable}} | {{KV EnableDisable}} | ||
Line 13: | Line 16: | ||
== Inputs == | == Inputs == | ||
{{ | {{I|SetTargetEntity|param=target|nofgd=1|Sets the target entity and begins output. The targetnames [[!activator]] and [[!caller]] are accepted.}} | ||
{{ | {{I|Toggle|Toggle the sensor between enabled and disabled.}} | ||
{{I EnableDisable}} | {{I EnableDisable}} | ||
== Outputs == | == Outputs == | ||
{{ | {{O|Distance|ac-is-this=1|Distance of the target entity away from this entity.|param=float}} |
Latest revision as of 10:08, 29 April 2025
![]() |
---|
CPointProximitySensor |
![]() |
point_proximity_sensor
is a point entity available in all Source games. It continuously outputs the distance from itself to a target entity.
Keyvalues
- Name (targetname) <string>[ Edit ]
- The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g.
parentname
ortarget
).
Also displayed in Hammer's 2D views and Entity Report.See also: Generic Keyvalues, Inputs and Outputs available to all entities
- Target Entity Name (target) <targetname>
- Name of the entity whose distance will be sensed.
Important:Target entity must exist when this entity spawns (can be set later via SetTargetEntity input).
- Pitch Yaw Roll (Y Z X) (angles) <QAngle>
- This entity's orientation in the world. Pitch is rotation around the Y axis, yaw is the rotation around the Z axis, roll is the rotation around the X axis.
- Start Disabled (StartDisabled) <boolean>
- Stay dormant until activated (with the
Enable
input).
Flags
- Test the distance as measured along the axis specified by our direction. : [1]
Inputs
- SetTargetEntity <targetname > !FGD
- Sets the target entity and begins output. The targetnames !activator and !caller are accepted.
- Toggle
- Toggle the sensor between enabled and disabled.
EnableDisable:
- Enable / Disable
- Enable/disable this entity from performing its task. It might also disappear from view.
Outputs
- Distance <float >
- !activator = !caller = this entity
Distance of the target entity away from this entity.