wierd format thingy
#1

does anyone know to what the '%.1f ' in this peace:

"~r~Vehicle Health: ~y~%.1f~n~~r~Vehicle Speed: ~y~%i KmH", VHealth[GetPlayerVehicleID(playerid)]/10,

converts the var in to?
Reply
#2

Lets say the actual float is: 46.230553

%.0f = 46
%.1f = 46.2
%.2f = 46.23

Should get the idea of how this works now :P

So basically this is used only to show the important numbers in the float...
Another example, instead of displaying 100.000000, Using %f.1 will only display 100.0
Reply
#3

tnx XGh0stz
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)