12.03.2011, 13:12
ok i made it like this
but when i do /slap 0 <dontdo>
it do the slap cmd with reason dondo
but when i do /slap 0 after the cmd above
its the same
* Kyro slaps 0 around a bit with a large trout.
slap cmd with reason : <the same reason i wrote in /slap 0 <donto>
why?
Код:
CMD:slap(playerid, params[]) { if(sscanf(params, "uS[128]", pid, creason)) return SendClientMessage(playerid, Grey, "Usage:/slap <id> <reason>"); if(isnull(creason)) { GetPlayerPos(pid, X, Y, Z); SetPlayerPos(pid, X, Y, Z+6); new Float:Health; GetPlayerHealth(pid,Health); SetPlayerHealth(pid,Health-20); PlayerPlaySound(playerid,1190,0.0,0.0,0.0); PlayerPlaySound(pid,1190,0.0,0.0,0.0); GetPlayerName(playerid, pname, 24); GetPlayerName(pid, gname, 24); format(sc, sizeof(sc), "AdmCmd:%s(%d) Was slapped by admin %s reason: Not specified", gname, pid, pname); SendClientMessageToAll(Red, sc); } else { GetPlayerPos(pid, X, Y, Z); SetPlayerPos(pid, X, Y, Z+6); new Float:Health; GetPlayerHealth(pid,Health); SetPlayerHealth(pid,Health-20); PlayerPlaySound(playerid,1190,0.0,0.0,0.0); PlayerPlaySound(pid,1190,0.0,0.0,0.0); GetPlayerName(playerid, pname, 24); GetPlayerName(pid, gname, 24); format(sc, sizeof(sc), "AdmCmd:%s(%d) Was slapped by admin %s reason: %s", gname, pid, pname, creason); SendClientMessageToAll(Red, sc); } return 1; }
it do the slap cmd with reason dondo
but when i do /slap 0 after the cmd above
its the same
* Kyro slaps 0 around a bit with a large trout.
slap cmd with reason : <the same reason i wrote in /slap 0 <donto>
why?