- เครดิต
- 254
- ความรู้
-
- เงิน $
-
- ความดี
-
|
คำสั่ง
if(strcmp(cmd, "/ÃÐàºÔ´", true) == 0)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
tmp = strtok(cmdtext, idx);
if(!strlen(tmp) && PlayerInfo[playerid][pAdmin] >= 2)
{
SendClientMessage(playerid, COLOR_GREY, "/explode [Playerid]");
return 1;
}
giveplayerid = ReturnUser(tmp);
GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
if(IsPlayerConnected(giveplayerid))
{
if(PlayerInfo[playerid][pAdmin] >= 4)
{
if(IsPlayerConnected(giveplayerid))
{
format(string, sizeof(string), "AdmCMD: %s was exploded by %s",giveplayer, sendername);
ABroadCast(COLOR_YELLOW,string,1);
//SendClientMessageToAll(COLOR_DBLUE, string);
SetPlayerHealth(giveplayerid, 10);
new Float:boomx, Float:boomy, Float:boomz;
GetPlayerPos(giveplayerid,boomx, boomy, boomz);
CreateExplosion(boomx, boomy , boomz, 7, 10);
new PlayerName[30];
GetPlayerName(playerid, PlayerName, 30);
printf("[Command] %s has used /explode to explode %s", PlayerName, giveplayer);
}
else
{
format(string, sizeof(string), "%d is not an active player.", giveplayerid);
SendClientMessage(playerid, COLOR_RED, string);
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "You do not have permission to use that command!");
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "You Must be logged in to use this command!");
}
return 1;
}
|
|