m cleanups |
fix type links |
||
Line 14: | Line 14: | ||
|}} | |}} | ||
The '''To String''' node turns various types, including objects, into strings. In general, this will match the string that a [[Display (ProtoFlux)|display node]] displays. Use cases include HUDs that involve numbers, such as turning your FPS into text for a display, or readouts of objects or values. | The '''To String''' node turns various types, including objects, into [[Type:String|strings]]. In general, this will match the string that a [[Display (ProtoFlux)|display node]] displays. Use cases include HUDs that involve numbers, such as turning your FPS into text for a display, or readouts of objects or values. | ||
== Inputs == | == Inputs == | ||
Line 21: | Line 21: | ||
The value to turn into a string. | The value to turn into a string. | ||
=== Format (String) === | === Format ([[Type:String|String]]) === | ||
A [https://learn.microsoft.com/en-us/dotnet/standard/base-types/composite-formatting#composite-format-string Composite Format String]. | A [https://learn.microsoft.com/en-us/dotnet/standard/base-types/composite-formatting#composite-format-string Composite Format String]. | ||
=== FormatProvider (IFormatProvider) === | === FormatProvider ([[Type:FormatProvider|IFormatProvider]]) === | ||
The locale to use for the output. Defaults to the invariant culture. | The locale to use for the output. Defaults to the invariant culture. | ||
== Outputs == | == Outputs == | ||
=== * (String) === | === * ([[Type:String|String]]) === | ||
The value as a string following the format. | The value as a string following the format. | ||
Revision as of 18:50, 15 January 2024
To String
Strings
The To String node turns various types, including objects, into strings. In general, this will match the string that a display node displays. Use cases include HUDs that involve numbers, such as turning your FPS into text for a display, or readouts of objects or values.
Inputs
V (Generic)
The value to turn into a string.
Format (String)
FormatProvider (IFormatProvider)
The locale to use for the output. Defaults to the invariant culture.
Outputs
* (String)
The value as a string following the format.
Examples
-
Four examples of converting various primitives to string. Three of the examples use Standard Numeric Format Strings.
-
Four examples of converting various objects to string. Note how, in general, the output matches what the display node outputs.