Float to integer?
#1

I've tried to to do this but leads me into a tag mismatch.
pawn Код:
new Float:hp = GetPlayerHealthEx(playerid),string[10];
    hp = floatround(hp,floatround_round);
    new integer:i;
    i = hp;
    format(string,sizeof(string),"%i",i);
    TextDrawSetString(Text:hptxt,string);
Reply
#2

pawn Код:
new Float:hp, string[10];
GetPlayerHealth(playerid, hp);
format(string, sizeof (string), "%i", floatround(hp, floatround_round);
TextDrawSetString(Text:hptxt, string);
Reply
#3

Thank you.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)