Use Math.floor/ceil instead of FloatMath

On SDK >= 8, Math.floor and Math.ceil are faster than FloatMath
equivalents.