18.01.2011, 14:47
I made it quickly so just try it. Should work perfectly though.
Not tested!
pawn Code:
cmd_healme(playerid, params[])
{
new pID, pHealth;
if(!sscanf(params, "ui",pID, pHealth))
{
if(IsPlayerConnected(pID))
{
if(pHealth > 1 || pHealth < 101)
{
SetPlayerHealth(pID, pHealth);
SendClientMessage(pID, 0x00FF00AA, "You have been healed");
}
else return SendClientMessage(playerid, 0xFFFFFFFF,"Error: Please use |Max|: 100, |Min|: 1");
}
else return SendClientMessage(playerid, 0xFFFFFFFF,"This player is not online.");
}
else return SendClientMessage(playerid, 0xFF0000AA, "Usage: \"/healme\"");//if he adds ANYTHING after healme this will come up.
return 1;
}