10.02.2013, 23:32
Thanks, is it a bad idea to do this?:
pawn Код:
public OnPlayerUpdate(playerid)
{
new Float:health, query[500], pname[24];
GetPlayerName(playerid, pname, 24);
GetPlayerHealth(playerid, health);
PlayerInfo[playerid][pHealth] = health;
format(query, sizeof(query), "UPDATE playerdata SET Health=%f WHERE Username='%s'",
PlayerInfo[playerid][pHealth],
pname);
mysql_query(query);
return 1;
}