Point angularvelocitysensor: Difference between revisions
Jump to navigation
Jump to search
In code, it is represented by the
(Cleanup) |
(Used KV/I/O BaseEntity templates. Template:in code -> Template:code class.) |
||
Line 1: | Line 1: | ||
{{base point|point_angularvelocitysensor}} It detects whether another entity's angular velocity meets or exceeds a threshold value. | {{base point|point_angularvelocitysensor}} | ||
It detects whether another entity's angular velocity meets or exceeds a threshold value. | |||
{{ | {{code class|CPointAngularVelocitySensor|PointAngularVelocitySensor.cpp}} | ||
== | == KeyValues == | ||
{{KV|Target Entity Name|target_destination|Name of the entity whose angular velocity will be sensed.}} | {{KV|Target Entity Name|intn=target|target_destination|Name of the entity whose angular velocity will be sensed.}} | ||
{{KV|Threshold Velocity|float|The threshold angular velocity to compare against, in degrees per second.}} | {{KV|Threshold Velocity|intn=threshold|float|The threshold angular velocity to compare against, in degrees per second.}} | ||
{{KV|Fire Interval|float|Angular velocity must cross the threshold for at least this long to fire.}} | {{KV|Fire Interval|intn=fireinterval|float|Angular velocity must cross the threshold for at least this long to fire.}} | ||
{{KV|Axis|vecline}} | {{KV|Axis|intn=axis|vecline}} | ||
{{KV|Use Axis Helper|boolean|Use axis helper to determine rotation values (clockwise/counter-clockwise).}} | {{KV|Use Axis Helper|intn=usehelper|boolean|Use axis helper to determine rotation values (clockwise/counter-clockwise).}} | ||
{{KV | {{KV BaseEntity}} | ||
== Inputs == | == Inputs == | ||
{{IO|Test|Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity, firing either the <code>OnGreaterThan</code>OrEqualTo or <code>OnLessThan</code> output based on the result.}} | {{IO|Test|Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity, firing either the <code>OnGreaterThan</code>OrEqualTo or <code>OnLessThan</code> output based on the result.}} | ||
{{IO|TestWithInterval|Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity. Once the Fire Interval expires, fires the appropriate test result output if the result is stable throughout the Fire Interval.}} | {{IO|TestWithInterval|Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity. Once the Fire Interval expires, fires the appropriate test result output if the result is stable throughout the Fire Interval.}} | ||
{{I | {{I BaseEntity}} | ||
== Outputs == | == Outputs == | ||
Line 23: | Line 24: | ||
{{IO|OnLessThanOrEqualTo|Fired when the Target Entity goes from faster than the threshold angular velocity to slower than the threshold angular velocity.}} | {{IO|OnLessThanOrEqualTo|Fired when the Target Entity goes from faster than the threshold angular velocity to slower than the threshold angular velocity.}} | ||
{{IO|OnEqualTo|Fired when the Target Entity reaches the threshold angular velocity from a different velocity.}} | {{IO|OnEqualTo|Fired when the Target Entity reaches the threshold angular velocity from a different velocity.}} | ||
{{O | {{O BaseEntity|l4d=1}} |
Revision as of 12:08, 15 May 2022
Template:Base point It detects whether another entity's angular velocity meets or exceeds a threshold value.

CPointAngularVelocitySensor
class, defined in thePointAngularVelocitySensor.cpp
file.
KeyValues
- Target Entity Name (target) <targetname>
- Name of the entity whose angular velocity will be sensed.
- Threshold Velocity (threshold) <float>
- The threshold angular velocity to compare against, in degrees per second.
- Fire Interval (fireinterval) <float>
- Angular velocity must cross the threshold for at least this long to fire.
- Axis (axis) <vector>
- Use Axis Helper (usehelper) <boolean>
- Use axis helper to determine rotation values (clockwise/counter-clockwise).
Inputs
- Test
- Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity, firing either the
OnGreaterThan
OrEqualTo orOnLessThan
output based on the result.
- TestWithInterval
- Checks to see if the Target Entity's angular velocity meets or exceeds the Threshold Velocity. Once the Fire Interval expires, fires the appropriate test result output if the result is stable throughout the Fire Interval.
Outputs
- AngularVelocity <float >
- Fired when the Target's Angular Velocity changes, passing the new magnitude of the angular velocity.
- OnGreaterThan
- Fired when the Target Entity goes from slower than the threshold angular velocity to faster than the threshold angular velocity.
- OnGreaterThanOrEqualTo
- Fired when the Target Entity goes from slower than the threshold angular velocity to faster than the threshold angular velocity.
- OnLessThan
- Fired when the Target Entity goes from faster than the threshold angular velocity to slower than the threshold angular velocity.
- OnLessThanOrEqualTo
- Fired when the Target Entity goes from faster than the threshold angular velocity to slower than the threshold angular velocity.
- OnEqualTo
- Fired when the Target Entity reaches the threshold angular velocity from a different velocity.