SA-MP Forums Archive
[Ajuda] Setar o player para [pProcurado] - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Setar o player para [pProcurado] (/showthread.php?tid=479678)



Setar o player para [pProcurado] - ofviac - 06.12.2013

olб gente!, eu crie um gm, mais estou com muita dificuldade em setar o Player para [pProcurados] alguem pode me ajudar ?, Obrigado


Re: Setar o player para [pProcurado] - P1c4550 - 06.12.2013

pProcurados? q porra e essa explique melhor oque vc quer '-'


Re: Setar o player para [pProcurado] - Menor - 06.12.2013

pProcurados ++;


Re: Setar o player para [pProcurado] - ofviac - 06.12.2013

Quote:
Originally Posted by P1c4550
Посмотреть сообщение
pProcurados? q porra e essa explique melhor oque vc quer '-'
й o seguinte , nгo tem aquele comando /su , que vocк dб uma estrelinha a ele e quando ele morre pelo policial ele vai preso?, tipo

PHP код:
if(PlayerInfo[playerid][pProcurado] >= 1)
    {
        if(
PlayerInfo[killerid][pBOPE] >= || PlayerInfo[killerid][pPMS] >= 1)
        {
            if(
EmTrabalho[killerid] == 1)
            {
                if(
PlayerInfo[playerid][pPresoLS] >= 1)
                {
                return 
1;
                   }
                new 
string[200];
                
GameTextForPlayer(playerid"~r~Preso!"25003);
                
GameTextForPlayer(killerid"~r~Suspeito abatido!"25003);
                
GivePlayerMoney(killerid100);
                
PlayerInfo[playerid][pPresoLS] = 1;
                
SetPlayerWantedLevel(playerid0);
                new 
pName1[24];
                new 
pName2[24];
                
GetPlayerName(playeridpName124);
                
GetPlayerName(killeridpName224);
                
format(stringsizeof(string), "<< O procurado da justiзa %s foi preso pelo Polнcial %s >>"pName1pName2);
                
SendClientMessageToAll(COLOR_KICK,string);
                    if(
PlayerInfo[playerid][pProcurado] == 1)
                {
                
PlayerInfo[playerid][pTempoPreso] = 180;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 2)
                {
                
PlayerInfo[playerid][pTempoPreso] = 240;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 3)
                {
                
PlayerInfo[playerid][pTempoPreso] = 300;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 4)
                {
                
PlayerInfo[playerid][pTempoPreso] = 400;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 5)
                {
                
PlayerInfo[playerid][pTempoPreso] = 500;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] >= 6)
                {
                
PlayerInfo[playerid][pTempoPreso] = 900;
                
SpawnPlayer(playerid);
                }
                
PlayerInfo[playerid][pProcurado] = 0;
            }
        }
        if(
PlayerInfo[killerid][pBOPE] >= || PlayerInfo[killerid][pPMS] >= 1)
        {
            if(
EmTrabalho[killerid] == 1)
            {
                if(
PlayerInfo[playerid][pPresoSF] >= 1)
                {
                return 
1;
                   }
                new 
string[200];
                
GameTextForPlayer(playerid"~r~Preso!"25003);
                
GameTextForPlayer(killerid"~r~Suspeito abatido!"25003);
                
GivePlayerMoney(killerid100);
                
PlayerInfo[playerid][pPresoSF] = 1;
                
SetPlayerWantedLevel(playerid0);
                new 
pName1[24];
                new 
pName2[24];
                
GetPlayerName(playeridpName124);
                
GetPlayerName(killeridpName224);
                
format(stringsizeof(string), "<< O procurado da justiзa %s foi preso pelo Polнcial %s >>"pName1pName2);
                
SendClientMessageToAll(COLOR_KICK,string);
                    if(
PlayerInfo[playerid][pProcurado] == 1)
                {
                
PlayerInfo[playerid][pTempoPreso] = 180;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 2)
                {
                
PlayerInfo[playerid][pTempoPreso] = 240;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 3)
                {
                
PlayerInfo[playerid][pTempoPreso] = 300;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 4)
                {
                
PlayerInfo[playerid][pTempoPreso] = 400;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] == 5)
                {
                
PlayerInfo[playerid][pTempoPreso] = 500;
                
SpawnPlayer(playerid);
                }
                if(
PlayerInfo[playerid][pProcurado] >= 6)
                {
                
PlayerInfo[playerid][pTempoPreso] = 900;
                
SpawnPlayer(playerid);
                }
                
PlayerInfo[playerid][pProcurado] = 0;
                }
            }
        } 
й o seguindo, eu quero dar nivel para o player e setar ele no [pProcurado] tipo o meu gm tб assim, quando o [pProcurado] morre ele vai preso, se ligou ?


Respuesta: Setar o player para [pProcurado] - ViniKuliveguisky - 06.12.2013

Exemplo de uso:
pawn Код:
CMD:su(playerid, params[])
{
    new giveplayerid, level;
    if(sscanf(params, "ui", giveplayerid, level)) return SendClientMessage(playerid, COLOR_WHITE, "* USE: /su [id] [level]");
    SetPlayerWantedLevel(giveplayerid, level);
    PlayerInfo[giveplayerid][pProcurado] += level;
}



Re: Respuesta: Setar o player para [pProcurado] - ofviac - 06.12.2013

Obrigado cara, mais agora o meu estб assim

PHP код:
if(!strcmp(cmd"/su"true))
{
     if(
PlayerInfo[playerid][pPMBA] >= || PlayerInfo[playerid][pPMS] >= 1) {
         
tmp strtok(cmdtextidx);
         if(!
strlen(tmp)) return SendClientMessage(playerid, -1"use /suspeito id");
         new 
suspeito strval(tmp);
         if(!
IsPlayerConnected(suspeito) || suspeito == INVALID_PLAYER_ID) return SendClientMessage(playerid, -1"O ID Digitado й um ID Invбlido!");
         new 
nome[MAX_PLAYER_NAME];
         
GetPlayerName(suspeitonomesizeof(nome));
         
format(stringsizeof(string), "*ATENЗГO: O Suspeito %s(%d) estб foragido, cerquem a favela e prendгo-no!",nome,playerid);
         
SendClientMessageToAll(0xFF80808B,string);
         
level[playerid] = GetPlayerWantedLevel(playerid)+1;
         return 
1
poderia fazer a junзгo com o seu ?