Revision Difference
string.ToColor#528449
<function name="ToColor" parent="string" type="libraryfunc">
<description>Fetches a Color type from a string.</description>
<realm>Shared and Menu</realm>
<file line="332">lua/includes/extensions/string.lua</file>
<args>
<arg name="Inputstring" type="string">The string to convert from.</arg>
</args>
<rets>
<ret name="" type="table">The output <page>Color</page></ret>
</rets>
</function>
<example>
<description>Demonstrates the use of string.ToColor</description>
<code>PrintTable( string.ToColor( "255 0 255 125" ) )</code>
<outputfixedwidth>Fixed width</outputfixedwidth>⤶
<output>
```⤶
r = 255
g = 0
b = 255
a = 125
```⤶
</output>
</example>