Struct EntityInputData ​
Namespace: ValveResourceFormat.Renderer.Entities
Assembly: Renderer.dll
The parameter and senders of an entity I/O input.
public readonly struct EntityInputDataProperties ​
Activator ​
Gets the entity that started the I/O chain.
public BaseEntity? Activator { get; init; }Property Value ​
Caller ​
Gets the entity that fired the output.
public BaseEntity? Caller { get; init; }Property Value ​
Parameter ​
Gets the parameter passed with the input, if any.
public string? Parameter { get; init; }Property Value ​
string?
Methods ​
Bool(bool) ​
Reads the parameter as a boolean, where an empty parameter is false.
public bool Bool(bool defaultValue = false)Parameters ​
defaultValue bool
The value returned when there is no parameter or it is not a boolean.
Returns ​
bool
Color() ​
Reads the parameter as an "R G B" or "R G B A" color, which is its red, green and blue as 0-255.
public Vector3? Color()Returns ​
The color, or null when the parameter is not three or four numbers.
Float(float) ​
Reads the number the parameter starts with, which is zero for text that is not a number.
public float Float(float defaultValue = 0)Parameters ​
defaultValue float
The value returned when there is no parameter.
Returns ​
float
FormatFloat(float) ​
Formats a float the way the game turns one into a string parameter: six decimals, with the trailing zeros stripped down to one, so 1 becomes 1.0 and 0.25 becomes 0.25.
public static string FormatFloat(float value)Parameters ​
value float
Returns ​
string
Int(int) ​
Reads the integer the parameter starts with, which is zero for text that is not a number.
public int Int(int defaultValue = 0)Parameters ​
defaultValue int
The value returned when there is no parameter.
Returns ​
int
Vector(Vector3) ​
Reads up to three space separated numbers from the parameter, with the missing ones zero.
public Vector3 Vector(Vector3 defaultValue = default)Parameters ​
defaultValue Vector3
The value returned when there is no parameter.

