StringParser.toNumber() - Mtax-Development/GML-OOP GitHub Wiki

Argument

Name
Type
Optional
decimalDotCount?
Yes

Returns

{real} | On error: {undefined}

Description

Return the string as a number if it contains numerical characters. A counter for the dot character can be specified to treat all remaining number characters as decimal places after that many dot characters were found in the string. Specifying it as 0 will treat the entire number as decimal. Specifying it as {noone} will treat the entire number as integer.

⚠️ **GitHub.com Fallback** ⚠️