Changed how float numbers are converted to JSON strings

The new function is faster and makes the decimal point easier to be added