Jail cmd
#4

To send a player to the jail ? :

PHP код:
if (strcmp("/jail"cmdtexttrue10) == 0)
    {
                new 
string[128];
            new 
ID;
            new 
cmdreason[128];
            new 
pname[24];
            
GetPlayerName(playerid,pname,sizeof(pname));
        if(
sscanf(params"uis[100]"IDcmdreason))
            {
               
SendClientMessage(playerid,-1,"Use: /jail (Pseudo/ID) (Reason)");
               return 
1;
            } 
                if(!
IsPlayerConnected(ID))
            {
                
format(string,sizeof(string),"Disconnected player.");
                
SendClientMessage(playerid,COLOR_ERROR,string);
                return 
1;
            }
                
SendClientMessage(ID, -1,  "You have been jailed by : %s",pname);
                
SetPlayerPos(IDYOUR JAIL POS);
                
SetPlayerInterior(IDYOUR INTERIOR);
        return 
1;
    } 
Hope this helps.

KillerDVX,
Reply


Messages In This Thread
Jail cmd - by TenTen - 11.07.2015, 23:29
Re: Jail cmd - by SilentSoul - 11.07.2015, 23:31
Re: Jail cmd - by TenTen - 11.07.2015, 23:58
Re : Jail cmd - by KillerDVX - 12.07.2015, 02:24
Re: Jail cmd - by TenTen - 12.07.2015, 02:36

Forum Jump:


Users browsing this thread: 1 Guest(s)