utils.round()

The utils.round() function rounds a value to two decimals.

Signature

Javascript
float utils.round(float value)

Example

Javascript
utils.round(0.1234) // 0.12
utils.round(5.6789) // 5.68