Logic compare

From Valve Developer Community
Revision as of 07:44, 7 January 2010 by TomEdwards (talk | contribs) (cleanup)
Jump to navigation Jump to search

Template:Base point It examines the relationship between two numbers ("value" and "compare value"), and fires appropriate output(s).

The equation is (value - compare value).

Keyvalues

InitialValue <int>
Initial value to compare.
CompareValue <int>
The value to compare against.
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

SetValue <float>
Set the value that will be compared.
SetValueCompare <float>
Set the value to compare, then perform a comparison.
SetCompareValue <float>
Set the value to compare against
Compare
Perform a comparison.


Outputs

OnEqualTo <float>
OnNotEqualTo <float>
OnGreaterThan <float>
OnLessThan <float>
The appropriate output(s) are fired when the Compare or SetValueCompare input is received. Each pass the input value.