28.05.2012, 06:08
Quote:
hp[3] is already an integer :P.
Anyway, just change pawn Код:
pawn Код:
|
Here is the final code if that will help anyone out in the futuuure:
pawn Код:
//===[Set Health]===
YCMD:sethp(playerid, hp[], help)
{
if (help)
{
SendClientMessage(playerid, 0xFF0000AA, "Set the player health to wanted number");
}
else
{
SetPlayerHealth(playerid, floatstr(hp)); //anything not a number above 1 seems to kill you, a check above here is probably a good idea!
}
return 1;
}