Yes the math.modf() function is a lua standard built in function of the math library.
You get both the integer and the fractional part of any number, float or integer, and since it’s likely written in C it’s faster than any Lua code snippet
http://lua-users.org/wiki/MathLibraryTutorial
Removing decimal places from a 'float' without rounding - example
Re: Removing decimal places from a 'float' without rounding - example
My YouTube Chanel on the A320 (Real SOPs by an Airline Pilot IRL):
https://www.youtube.com/playlist?list=P ... 0Q6SBASRqJ
https://www.youtube.com/playlist?list=P ... 0Q6SBASRqJ