SA-MP Forums Archive
[Ajuda] ajuda 5 Warnings gm nao liga - 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] ajuda 5 Warnings gm nao liga (/showthread.php?tid=641950)

Pages: 1 2


ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

boa tarde alguem poderia me ajudar com essas Warnings?

PHP Code:
C:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17483) : warning 219local variable "NomePlayer" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17520) : warning 219local variable "NomePlayer" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17528) : warning 219local variable "NomePlayer" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17590) : warning 219local variable "NomePlayer" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(76638) : warning 219local variable "NomePlayer" shadows a variable at a preceding level
Pawn compiler 3.2.3664              Copyright 
(c1997-2006ITB CompuPhase
5 Warnings

eu ja tentei remover as new pensei que esta repetida e deu um monte erro o que posso fazer para sair esses warnings?

codigos:

linha 17483:
PHP Code:
                new NomePlayer[MAX_PLAYER_NAME]; 
linha 17520:
PHP Code:
            new NomePlayer[MAX_PLAYER_NAME], NomeKiller[MAX_PLAYER_NAME]; 
linha 17528:
PHP Code:
            new NomePlayer[MAX_PLAYER_NAME], NomeKiller[MAX_PLAYER_NAME],ArmaTeste[32]; 
linha 17590:
PHP Code:
                            new NomePlayer[MAX_PLAYER_NAME], NomeKiller[MAX_PLAYER_NAME]; 
linha 76638:
PHP Code:
            new NomePlayer[MAX_PLAYER_NAME]; 
por favor se alguem puder me ajudar eu nao sei o que fazer


Re: ajuda 5 Warnings gm nao liga - BrunoLuiz - 22.09.2017

#pragma tabsize 0

coloca no inicio do gm


Re: ajuda 5 Warnings gm nao liga - C4rtm4n - 22.09.2017

Tenta mudar o nome da variavel NomePlayer.


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

Quote:
Originally Posted by BrunoLuiz
View Post
#pragma tabsize 0

coloca no inicio do gm
nao deu em nada fico a mesma coisa


Re: ajuda 5 Warnings gm nao liga - C4rtm4n - 22.09.2017

Quote:
Originally Posted by igor97m
View Post
nao deu em nada fico a mesma coisa
Da Proxima vez que me ignorar nгo irei ajudar tenta mudar o nome da variavel nomeplayer.


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

Quote:
Originally Posted by C4rtm4n
View Post
Da Proxima vez que me ignorar nгo irei ajudar tenta mudar o nome da variavel nomeplayer.
calma ai mano nao ignorei to tentando fazer aqui... deu certo mais no final deu 2 erro


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

deu certo saiu os warnings mais nesse deu erro

PHP Code:
C:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17590) : warning 219local variable "NomePlayer4" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play Futurama\gamemodes\BRF.pwn(29794) : error 017undefined symbol "NomePlayer4"
C:\Users\igorm\Desktop\Play Futurama\gamemodes\BRF.pwn(29798) : error 017undefined symbol "NomePlayer4"
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
2 Errors




Re: ajuda 5 Warnings gm nao liga - C4rtm4n - 22.09.2017

Quote:
Originally Posted by igor97m
View Post
deu certo saiu os warnings mais nesse deu erro

PHP Code:
C:\Users\igorm\Desktop\Play\gamemodes\BRF.pwn(17590) : warning 219local variable "NomePlayer4" shadows a variable at a preceding level
C
:\Users\igorm\Desktop\Play Futurama\gamemodes\BRF.pwn(29794) : error 017undefined symbol "NomePlayer4"
C:\Users\igorm\Desktop\Play Futurama\gamemodes\BRF.pwn(29798) : error 017undefined symbol "NomePlayer4"
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
2 Errors

Mesmo Erro mude para outro nome agora o erro й que nгo esta definido

variavel nomeplayer4 nгo esta definida ou seja vocк nгo criou uma variavel

new nomeplayer4[MAX_PLAYERS][MAX_PLAYER_NAME];

.


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

consegui aqui mano troquei os nome deu certo sу que tipo o gm ta compilando tudo certinho sу que nao ta ligando o server ta dando isso no samp-server
PHP Code:
Script[gamemodes/BRF.amx]: Run time error 19"File or function is not found" 
sу que ta tudo cert no gamemod ta compilando o que sera que й?


Re: ajuda 5 Warnings gm nao liga - C4rtm4n - 22.09.2017

Quote:
Originally Posted by igor97m
View Post
consegui aqui mano troquei os nome deu certo sу que tipo o gm ta compilando tudo certinho sу que nao ta ligando o server ta dando isso no samp-server
PHP Code:
Script[gamemodes/BRF.amx]: Run time error 19"File or function is not found" 
sу que ta tudo cert no gamemod ta compilando o que sera que й?
Vocк colocou as matriz

[MAX_PLAYERS] e [MAX_PLAYER_NAME]

? MANDE O CУDIGO DA ONDE TAVA DANDO O ERRO MAS MANDE COMPLETO.


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

Eu nem mexi nos codigo sу mudei que coloquei numero 1, 2, 3, 4, e 5 no final de cada uma ai deu certo mais tipo isso ja tava dando antes de arrumar os warnings atй pensei que era por causa disso mais nao й ta compilando tudo certo o gm mais o gm nao liga ta dando erro

PHP Code:
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase 
compilando sem erros e sem warnings


Re: ajuda 5 Warnings gm nao liga - C4rtm4n - 22.09.2017

Quote:
Originally Posted by igor97m
View Post
Eu nem mexi nos codigo sу mudei que coloquei numero 1, 2, 3, 4, e 5 no final de cada uma ai deu certo mais tipo isso ja tava dando antes de arrumar os warnings atй pensei que era por causa disso mais nao й ta compilando tudo certo o gm mais o gm nao liga ta dando erro

PHP Code:
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase 
compilando sem erros e sem warnings
Manda logo mano,vocк deve ter esqueзido alguma coisa.


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

PHP Code:
                            new NomePlayer4[MAX_PLAYER_NAME], NomeKiller[MAX_PLAYER_NAME];
                            
GetPlayerName(playerid,NomePlayer4,sizeof(NomePlayer4));
                            
GetPlayerName(killerid,NomeKiller,sizeof(NomeKiller));
                            
format(stringsizeof(string), "AdmAviso: %s[ORG: %s] Compriu Contrato Em %s [ORG:%s]"PlayerName(killerid), NomeORG(killerid), PlayerName(playerid), NomeORG(playerid));
                            
ABroadCast(0xFF6347AA,string,1);
                        }
                        if(
GetPlayerOrg(killerid) == 8)
                        {
                            
InfoCont[1]++;
                        }
                        else if(
GetPlayerOrg(killerid) == 24)
                        {
                            
InfoCont[2]++;
                        }
                        
PlayerInfo[playerid][pHeadValue] = 0;
                        
GotHit[playerid] = 0;
                        
GetChased[playerid] = 999;
                        
GoChase[killerid] = 999;
                    }
                }
            }
        } 
PHP Code:
        new string[MAX_STRING];
        
format(stringsizeof string"[DM]: %s [ID: %d] acusou %s [ID: %d], resultado: %s"NomePlayer(playerid),playerid,NomePlayer(id),id,ResultadoDM(playerid,id));
        
ABroadCast(COLOR_LIGHTRED,string,1);
        
BPFLogs("DM"string); 
o erro estava aqui que mudei para NomePlayer4 tambem mais nao tem nada a ver com o outro ai voltei ele ao normal e deu certo


Re: ajuda 5 Warnings gm nao liga - BrunoLuiz - 22.09.2017

atualize as plugin necessaria que dб agora, esse erro й de falta de plugin ou alguma estб desatualizada.


Re: ajuda 5 Warnings gm nao liga - IlanZ - 22.09.2017

Quote:
Originally Posted by BrunoLuiz
View Post
atualize as plugin necessaria que dб agora, esse erro й de falta de plugin ou alguma estб desatualizada.
WTF?


Re: ajuda 5 Warnings gm nao liga - BrunoLuiz - 22.09.2017

Quote:
Originally Posted by IlanZ
View Post
WTF?
Script[gamemodes/BRF.amx]: Run time error 19: "File or function is not found"


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

eu acho que o problema esta no plugin streamer pois eu ponho um de outro server meu ele liga o server mais some todos objetos e atualizo o plugin streamer da erro no gamemode


Re: ajuda 5 Warnings gm nao liga - BrunoLuiz - 22.09.2017

Quote:
Originally Posted by igor97m
View Post
eu acho que o problema esta no plugin streamer pois eu ponho um de outro server meu ele liga o server mais some todos objetos e atualizo o plugin streamer da erro no gamemode
atualize as plugin cara..


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

entao mano isso que to dizendo eu atualizo ele e nao funciona o gm dai eu ponho um streamer que tem no outro gm ele liga sу que fica bugado


Re: ajuda 5 Warnings gm nao liga - igor97m - 22.09.2017

ai deu certo mais agora ta dando erro nessa public

PHP Code:
forward KelveBlindagem(vehicleidplayerid);
public 
KelveBlindagem(vehicleidplayerid)
{
    for(new 
car 1car <= MAX_VEHICLEScar++)
     {
          if(
EstaBlindado[car] > 0)
        {
            new 
Float:lataria;
              
GetVehicleHealth(carlataria);
            if(
lataria 999)
            {
                   
EstaBlindado[car] -= 5;
                   
RepairVehicle(car);
                   return 
0;
            }
           }
    }
     return 
1;

fica aparecendo toda hora no samp-server
PHP Code:
[debugAMX backtrace:
[
debug#0 003e72e0 in public KelveBlindagem () from BRF.amx
[debugRun time error 4"Array index out of bounds"
[debug]  Attempted to read/write array element at index 2000 in array of size 2000