How to make a ..
#5

With dcmd + scanff

Copyed this from my admin script.

pawn Код:
dcmd_slap(playerid, params[])
{
    new slapid;
    new string[128];
    new reason[128];

    if(sscanf(params, "uz", slapid, reason)) return SendClientMessage(playerid,red,"Error: /slap <playerid/name> Reason.");
    if(!IsPlayerConnected(slapid) || slapid == INVALID_PLAYER_ID || slapid == playerid) return SendClientMessage(playerid,red,"Error: Player is not connected or it is yourself.");
    format(string,sizeof(string),"Admin: %s(id: %d) has slapped %s(id: %d) Reason: %s.",UserUD[playerid][accname],playerid,UserUD[slapid][accname],slapid,reason);
    SendClientMessageToAll(adminaction,string);

    new Float:x,
        Float:y,
        Float:z;
    GetPlayerPos(slapid, x,y,z);
    SetPlayerPos(slapid, x, y, z+8);
    PlayerPlaySound(slapid, 1190, 0,0,0);
    }
    return 1;
}
Reply


Messages In This Thread
How to make a .. - by Matej_ - 18.09.2010, 07:04
Re: How to make a .. - by nejc001 - 18.09.2010, 07:11
Re: How to make a .. - by Kyosaur - 18.09.2010, 07:13
Re: How to make a .. - by Matej_ - 18.09.2010, 08:35
Re: How to make a .. - by Seven. - 18.09.2010, 08:38
Re: How to make a .. - by Dime - 18.09.2010, 08:43
Re: How to make a .. - by Matej_ - 18.09.2010, 09:09
Re: How to make a .. - by Matej_ - 18.09.2010, 09:29
Re: How to make a .. - by Dime - 18.09.2010, 09:35
Re: How to make a .. - by Matej_ - 18.09.2010, 09:37

Forum Jump:


Users browsing this thread: 2 Guest(s)