[Ajuda] Comando /190
#4

PHP код:
    if(strcmp(cmd"/tirarsu"true) == 0)
    {
        if(
IsPlayerConnected(playerid))
        {
            if (
PlayerInfo[playerid][pAdmin] >= AKI VC SETA O ADMIN OU TIRA ESSA LINHA PARA O JOGADOR)
            {
                
tmp strtok(cmdtextidx);
                if(!
strlen(tmp))
                {
                    
SendClientMessage(playeridCOLOR_GRAD2"USE: (/tirarsu) [id] 0");
                    return 
true;
                }
                
giveplayerid ReturnUser(tmp);
                if(
IsPlayerConnected(giveplayerid))
                {
                    if(
giveplayerid != INVALID_PLAYER_ID)
                    {
                        
GetPlayerName(giveplayeridgiveplayersizeof(giveplayer));
                        
GetPlayerName(playeridsendernamesizeof(sendername));
                          
//new playerid;
                        
new length strlen(cmdtext);
                        while ((
idx length) && (cmdtext[idx] <= ' '))
                        {
                            
idx++;
                        }
                        new 
offset idx;
                        new 
result[64];
                        while ((
idx length) && ((idx offset) < (sizeof(result) - 1)))
                        {
                            
result[idx offset] = cmdtext[idx];
                            
idx++;
                        }
                        
result[idx offset] = EOS;
                        if(!
strlen(result))
                        {
                            
SendClientMessage(playeridCOLOR_GRAD2"USE: (/tirarsu [id] 0");
                            return 
true;
                        }
                        
WantedPoints[playerid] = 0;
                        
SetPlayerWantedLevel(playerid0);
                        return 
true;
                    }
                }
                else
                {
                    
SendClientMessage(playeridCOLOR_GRAD1"  Esse jogador nгo estб conectado.");
                    return 
true;
                }
               }
        }
        return 
true;
    } 
se ajudei +rep
Reply


Messages In This Thread
Comando /190 - by comanfiss - 05.04.2014, 17:00
Re: Comando /190 - by P1c4550 - 06.04.2014, 02:40
Re: Comando /190 - by comanfiss - 06.04.2014, 05:13
Re: Comando /190 - by HHwilliamHH - 06.04.2014, 12:30
Re: Comando /190 - by Lipe_Stronda - 06.04.2014, 13:21
Re: Comando /190 - by comanfiss - 06.04.2014, 16:21
Re: Comando /190 - by comanfiss - 06.04.2014, 16:23
Re: Comando /190 - by comanfiss - 06.04.2014, 16:28
Re: Comando /190 - by Lipe_Stronda - 06.04.2014, 17:15
Re: Comando /190 - by comanfiss - 06.04.2014, 17:17

Forum Jump:


Users browsing this thread: 1 Guest(s)