SA-MP Forums Archive
[Ajuda] /rg nao fecha - 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] /rg nao fecha (/showthread.php?tid=165461)



[Ajuda] /rg nao fecha - azull - 04.08.2010

Tou usando o GameMode do Thug v2.6 , mas nao tem como fechar o /rg pelo que vi

A gente coloca /rg e o rg abre...
Depois para fechar eu tento dar /rg e nao fecha
Ja vi e revi o GM todo e nao vi nenhum comando para fechar o /rg

Como й que faзo ??

O codigo ....

pawn Код:
if (strcmp(cmd, "/rg", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (gPlayerLogged[playerid] != 0)
            {
                ShowStats(playerid,playerid);
                GetPlayerName(playerid, sendername, sizeof(sendername));
                format(string, sizeof(string), "* %s Abre sua carteira e confere o Rg.", sendername);
                ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD1, "   Voce nao esta logado !");
            }
        }
        return 1;
    }



Re: [Ajuda] /rg nao fecha - Marco_Nutz - 04.08.2010

Ta aн, n testei....

pawn Код:
if (strcmp(cmd, "/rg", true) == 0)
    {
     if(IsPlayerConnected(playerid))
         {
            if (gPlayerLogged[playerid] != 0)
            {
            if (PoderosoInfo[playerid][PAbriuRG] = 0)
            {
             ShowStats(playerid,playerid);
             PoderosoInfo[playerid][PAbriuRG] = 1
             GetPlayerName(playerid, sendername, sizeof(sendername));
             format(string, sizeof(string), "* %s Abre sua carteira e confere o Rg.", sendername);
             ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
             }
             else if (PoderosoInfo[playerid][PAbriuRG] = 1)
             {
            TextDrawDestroy(playerid,LRGBox[playerid]);
            TextDrawDestroy(playerid,LRGBox2[playerid]);
            TextDrawDestroy(playerid,LRGBox3[playerid]);
            TextDrawDestroy(playerid,LRGBox4[playerid]);
            TextDrawDestroy(playerid,LRGBox5[playerid]);
            TextDrawDestroy(playerid,LRGBox6[playerid]);
            TextDrawDestroy(playerid,LRGBox7[playerid]);
            TextDrawDestroy(playerid,LRGBox8[playerid]);
            TextDrawDestroy(playerid,NickRGBox[playerid]);
             PoderosoInfo[playerid][PAbriuRG] = 0
             GetPlayerName(playerid, sendername, sizeof(sendername));
             format(string, sizeof(string), "* %s Fechou sua carteira.", sendername);
             ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
             }
             }
             else
             {
             SendClientMessage(playerid, COLOR_GRAD1, "   Voce nao esta logado !");
             }
             }        return 1;
             }
Se funfar, fala


Re: [Ajuda] /rg nao fecha - Diogo_braz - 05.08.2010

pawn Код:
if (strcmp(cmd, "/rg", true) == 0)
    {
     if(IsPlayerConnected(playerid))
         {
            if (gPlayerLogged[playerid] != 0)
            {
            if (PoderosoInfo[playerid][PAbriuRG] = 0)
            {
             ShowStats(playerid,playerid);
             PoderosoInfo[playerid][PAbriuRG] = 1
             GetPlayerName(playerid, sendername, sizeof(sendername));
             format(string, sizeof(string), "* %s Abre sua carteira e confere o Rg.", sendername);
             ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
             }
             else if (PoderosoInfo[playerid][PAbriuRG] = 1)
             {
            TextDrawHideForPlayer(playerid,LRGBox[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox2[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox3[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox4[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox5[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox6[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox7[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox8[playerid]);
            TextDrawHideForPlayer(playerid,NickRGBox[playerid]);
             PoderosoInfo[playerid][PAbriuRG] = 0
             GetPlayerName(playerid, sendername, sizeof(sendername));
             format(string, sizeof(string), "* %s Fechou sua carteira.", sendername);
             ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
             }
             }
             else
             {
             SendClientMessage(playerid, COLOR_GRAD1, "   Voce nao esta logado !");
             }
             }        return 1;
Seria assim porque ele nunca mais vai aparecer so com /gmx mano assim ja funciona acho eu...


Re: [Ajuda] /rg nao fecha - azull - 05.08.2010

Nenhum funcionou, no do Marco_Nutz deu esses erros ao compilar :

Код:
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13075) : warning 211: possibly unintended assignment
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13079) : error 001: expected token: ";", but found "-identifier-"
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13083) : warning 211: possibly unintended assignment
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13085) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13085) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13086) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13086) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13087) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13087) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13088) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13088) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13089) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13089) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13090) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13090) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13091) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13091) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13092) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13092) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13093) : warning 213: tag mismatch
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13093) : warning 202: number of arguments does not match definition
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(13095) : error 001: expected token: ";", but found "-identifier-"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
E no do Diogo_Braz deu esses erros :

Код:
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(766) : error 004: function "SaveAdmin" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(772) : error 004: function "SaveCars" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2171) : error 017: undefined symbol "GivePlayerMoneyEx"
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2200) : error 017: undefined symbol "GivePlayerMoneyEx"
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2392) : error 004: function "BoxdaGuerra" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2497) : error 004: function "DetectorProx" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2572) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2576) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2588) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2592) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2596) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2600) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2604) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2608) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2612) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2624) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2628) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2632) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2636) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2640) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2652) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2656) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2660) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2672) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(2676) : error 004: function "PlayerToPoint" is not implemented
C:\Documents and Settings\A\Ambiente de trabalho\Leep\SAMP~GTA\Server Life Is Good\gamemodes\LG26.pwn(3555) : error 017: undefined symbol "GivePlayerMoneyEx"

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


26 Errors.
Ajuda '-'


Re: [Ajuda] /rg nao fecha - Diogo_braz - 05.08.2010

Mano vou te passar assim olha o /rg deixa normal para abrir como estava!!

e faz assim um novo comando:

pawn Код:
}
//-------------------------------[Sair /rg by: Most_Wanted]--------------------------------------------------------------------------
    if (strcmp(cmd, "/sairrg", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (gPlayerLogged[playerid] != 0)
            {
                            TextDrawHideForPlayer(playerid,LRGBox[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox2[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox3[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox4[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox5[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox6[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox7[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox8[playerid]);
            TextDrawHideForPlayer(playerid,NickRGBox[playerid]);
             PoderosoInfo[playerid][PAbriuRG] = 0;
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD1, "   Vocк nгo esta logado !");
   }
        }
        return 1;
Tenta isso e me fala aew mano


Re: [Ajuda] /rg nao fecha - [BEP]AcerPilot - 05.08.2010

Os dois fizeram o mesmo erro. Quando se usa o argumento 'if', vocк compara dois itens, por isso, quando quer se checar se dois itens sгo iguais, nгo se usa sу um '=', se usa dois:

pawn Код:
if (PoderosoInfo[playerid][PAbriuRG] == 0)

else if (PoderosoInfo[playerid][PAbriuRG] == 1)
Se usa sу um quando se quer igualar dois itens:

pawn Код:
EsteItemEh = AEste;
Sacaram?


Re: [Ajuda] /rg nao fecha - Flavinho153 - 05.08.2010

Passa o RG jб aberto ...com nivel etc...porq deve ter um treco 0 e 1 ali..


Re: [Ajuda] /rg nao fecha - Marco_Nutz - 05.08.2010

Quote:
Originally Posted by [BEP]GeoPilot
Посмотреть сообщение
Os dois fizeram o mesmo erro. Quando se usa o argumento 'if', vocк compara dois itens, por isso, quando quer se checar se dois itens sгo iguais, nгo se usa sу um '=', se usa dois:

pawn Код:
if (PoderosoInfo[playerid][PAbriuRG] == 0)

else if (PoderosoInfo[playerid][PAbriuRG] == 1)
Se usa sу um quando se quer igualar dois itens:

pawn Код:
EsteItemEh = AEste;
Sacaram?
e.e eu botei desse jeito =x

EDIT: Entendi errado, й, eskeci d botar os dois == =x


Re: [Ajuda] /rg nao fecha - azull - 05.08.2010

Quote:
Originally Posted by Diogo_braz
Посмотреть сообщение
Mano vou te passar assim olha o /rg deixa normal para abrir como estava!!

e faz assim um novo comando:

pawn Код:
}
//-------------------------------[Sair /rg by: Most_Wanted]--------------------------------------------------------------------------
    if (strcmp(cmd, "/sairrg", true) == 0)
    {
        if(IsPlayerConnected(playerid))
        {
            if (gPlayerLogged[playerid] != 0)
            {
                            TextDrawHideForPlayer(playerid,LRGBox[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox2[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox3[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox4[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox5[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox6[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox7[playerid]);
            TextDrawHideForPlayer(playerid,LRGBox8[playerid]);
            TextDrawHideForPlayer(playerid,NickRGBox[playerid]);
             PoderosoInfo[playerid][PAbriuRG] = 0;
            }
            else
            {
                SendClientMessage(playerid, COLOR_GRAD1, "   Vocк nгo esta logado !");
   }
        }
        return 1;
Tenta isso e me fala aew mano
faltou fechar o codigo
depois do return 1; tem que ter o } kk fail

mas mesmo assim , eu botei isso , loguei la no sv dei /rg
e depois /sairrg
saiu tudo menos o quadrado preto do fundo , como faz agr ? kK


Re: [Ajuda] /rg nao fecha - BiieL - 05.08.2010

tipo so explicar melhor o q geo disse:

Sinal "=": qr dizer que vc vai receber uma funзгo
Sinal "==": ai sim qr dizer q eh igual

sacaram melhor?