Scripting help
#2

pawn Код:
#include <a_samp>
#include <sscanf2>
#include <zcmd>

CMD:akill(playerid, params[])
{
    new target;

    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You're not an admin!");
    if(sscanf(params, "u", target)) return SendClientMessage(playerid, -1, "/akill [ID/PartOfName]");

    SetPlayerHealth(target, 0);

    return true;
}

CMD:akillall(playerid, params[])
{
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You're not an admin!");

    for(new i; i < GetMaxPlayers(); i ++) SetPlayerHealth(i, 0);

    return true;
}
Reply


Messages In This Thread
Scripting help - by kirostar - 02.07.2014, 03:04
Re: Scripting help - by Dignity - 02.07.2014, 03:11
Re: Scripting help - by kirostar - 02.07.2014, 03:16
Re: Scripting help - by Dignity - 02.07.2014, 03:20
Re: Scripting help - by kirostar - 02.07.2014, 03:21
Re: Scripting help - by OKStyle - 02.07.2014, 03:22
Re: Scripting help - by kirostar - 02.07.2014, 03:24
Re: Scripting help - by Dignity - 02.07.2014, 03:35
Re: Scripting help - by kirostar - 02.07.2014, 03:35
Re: Scripting help - by OKStyle - 02.07.2014, 03:41

Forum Jump:


Users browsing this thread: 2 Guest(s)