[Ajuda] Ao colocar Sistema de helpers em GM
#1

Sгo 2 erros o 1 :
Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(962) : error 009: invalid array size (negative, zero or out of bounds)
Local do erro:
Код:
new AdmInfo[31][Admin];
new HelperInfo[21][Helper];
2 Erro:

Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 017: undefined symbol "helperhide"
Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 029: invalid expression, assumed zero
Local do erro:

Код:
admhide[playerid] = 0;
helperhide[playerid] = 0;
Se alguem puder me ajudar a arrumar os erros agradeзo.
Reply
#2

Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(962) : error 009: invalid array size (negative, zero or out of bounds)
voce ta declarando essa matriz multidimenssional errado!
pawn Код:
new AdmInfo[31][Admin];//Da o Valor de 0
new HelperInfo[21][Helper];//Da o Valor de 0
Em vez de [Admin] e [Helper] Use assim por exemplo:

pawn Код:
new HelperInfo[8][20] = {
"Aspira a Helper",
"Helper Iniciante",
"Helper Intermediбrio",
"Helper Avanзado",
"Helper Graduado",
"Helper Pos Graduado",
"Helper Senior",
"Helper Chefe",
};
Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 017: undefined symbol "helperhide"
Simbolo helperhide nao definido

Vai no topo do GM e adciona
pawn Код:
helperhide[MAX_PLAYERS];
Код:
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Igor\Desktop\Brasil Play Street\gamemodes\BPS.pwn(7741) : error 029: invalid expression, assumed zero
Posta a Linha, mais pelo primeiro erro diz que falta ";" na linha 7740
Reply
#3

defina no topo do gm...
pawn Код:
new admhide[MAX_PLAYERS], helperhide[MAX_PLAYERS];

E o sistema de admin, poderia ser assim tambem \/
pawn Код:
enum PlayerInfo
{
    pAdmin,
    pHelper
}

new PlayerInfo[MAX_PLAYERS][PlayerInfo];
Espero ter ajudado
Modo de uso:
pawn Код:
PlayerInfo[playerid][pAdmin] = 5;
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)