Floatround

From SA-MP Wiki

Jump to: navigation, search

floatround

Image:Farm-Fresh text lowercase.png Note: This function name starts with a lowercase letter.


Description:

Round a floating point number to an integer value.


Parameters:
(Float:value,method = floatround_round)
valueThe value to round.
methodThe floatround method to use.


Return Values:

The rounded value as an integer.


Example Usage:

floatround(3.3, floatround_ceil);


Related Functions

The following functions may be useful, as they are related to this function in one way or another.

  • float: Convert an integer to a float.
  • floatstr: Convert an string to a float.
Personal tools
Navigation
Toolbox