C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(705) : error 017: undefined symbol "Orgnome" C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(705) : warning 215: expression has no effect C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(705) : error 001: expected token: ";", but found "]" C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(705) : error 029: invalid expression, assumed zero C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(705) : fatal error 107: too many error messages on one line
C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(706) : error 028: invalid subscript (not an array or too many subscripts): "Orgnome"
CMD:membros(playerid)
{
new corda[70];
for(new i, PP = GetMaxPlayers(); i < PP; i++)
{
if(!IsPlayerConnected(PP)) continue;
if(ProgressaoInfo[i][Membro] == ProgressaoInfo[playerid][Membro])
{
new nome[MAX_PLAYER_NAME];
new Orgnome;
GetPlayerName(playerid, nome, sizeof(nome));
format(corda, sizeof(corda), "{00FF66}%s {FFFF00}Org: {00FF66}%s {FFFFFF}|| {FFFF00}Cargo: {00FF66}%d\n", nome, Orgnome[ProgressaoInfo[i][Membro]], ProgressaoInfo[i][Cargo]);
strcat(Texto, corda, 70);
}
}
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_MSGBOX, "Lista de membros online", Texto, "OK", "");
strdel(Texto, 0, sizeof(Texto));
return true;
}
format(corda, sizeof(corda), "{00FF66}%s {FFFF00}Org: {00FF66}%s {FFFFFF}|| {FFFF00}Cargo: {00FF66}%d\n", nome, Nomeorgs[ProgressaoInfo[i][Membro]], ProgressaoInfo[i][Cargo]);
C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(177) : error 001: expected token: "}", but found "-string-" C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(792) : warning 213: tag mismatch C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(884) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(885) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1556) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1557) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1427) : warning 204: symbol is assigned a value that is never used: "ParkourIniciou"
C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(793) : warning 213: tag mismatch C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(885) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(886) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1557) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1558) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1.pwn(1428) : warning 204: symbol is assigned a value that is never used: "ParkourIniciou"
for(new i = 0, PP = GetMaxPlayers(); i < PP; i++)
C:\Users\PC\Desktop\Minha GM\gamemodes\barev1comorg.pwn(793) : warning 213: tag mismatch C:\Users\PC\Desktop\Minha GM\gamemodes\barev1comorg.pwn(1274) : warning 213: tag mismatch C:\Users\PC\Desktop\Minha GM\gamemodes\barev1comorg.pwn(1275) : warning 213: tag mismatch C:\Users\PC\Desktop\Minha GM\gamemodes\barev1comorg.pwn(1563) : warning 202: number of arguments does not match definition C:\Users\PC\Desktop\Minha GM\gamemodes\barev1comorg.pwn(1564) : warning 202: number of arguments does not match definition
CMD:promover(playerid, params[])
{
new PlayerB, cargo;
if(sscanf(params, "d", PlayerB, Cargo)) return SendClientMessage(playerid, COLOR_ERRO, "[ x ] Uso correto: /Promover [id] [cargo]");
if(ProgressaoInfo[playerid][Cargo] != 10) return SendClientMessage(playerid, COLOR_ERRO, "[ x ] Vocк nгo й lнder.");
if(ProgressaoInfo[PlayerB][Membro] != ProgressaoInfo[playerid][Membro]) return SendClientMessage(playerid, COLOR_ERRO, "[ X ] Este jogador nгo й da mesma organizaзгo que vocк.");
ProgressaoInfo[playerid][Cargo] = cargo;
return true;
}
LoadPlayer(playerid)
{
if( DOF2_FileExists( GetPlayerArquivo( playerid ) ) )
{
Player[ playerid ][ Score ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Score");
Player[ playerid ][ Dinheiro ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Dinheiro");
Player[ playerid ][ Fundador ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Fundador");
Player[ playerid ][ Gerente ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Gerente");
Player[ playerid ][ Admin ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Admin");
Player[ playerid ][ Matou ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Matou");
Player[ playerid ][ Morreu ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Morreu");
Player[ playerid ][ Membro ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Membro"); //Linha do erro
Player[ playerid ][ Cargo ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Cargo"); //Linha do erro
SetPlayerScore( playerid, Player[ playerid ][ Score ] );
GivePlayerMoney( playerid, Player[ playerid] [ Dinheiro ] );
}
return 1;
}
stock SalvarPlayer(playerid)
{
new nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, nome, sizeof(nome));
format(Texto, 35, "Jogadores/%s", nome);
DOF2_FileExists(Texto);
DOF2_SetInt("Membro", ProgressaoInfo[playerid][Membro]); //Linha do erro
DOF2_SetInt("Cargo", ProgressaoInfo[playerid][Cargo]); //Linha do erro
DOF2_SaveFile();
DOF2_Exit();
return true;
}
if(sscanf(params, "dd", PlayerB, cargo))
new Texto[256];
enum Info
{
Membro,
Cargo,
};
new ProgressaoInfo[MAX_PLAYERS][Info];
new Nomeorgs[5][128] = //[5]
{
"Civil",
"Assassinos",
"Aeronautica",
"Drifters",
"Policial Federal"
};
const C_Civil = 0xFFFFFFFF;
const C_Assassinos = 0x000000FF;
const C_Aeronautica = 0x1E90FF99;
const C_Drifters = 0x1E90AA99;
const C_PFederal = 0x6C7B8BFF;
LoadPlayer(playerid)
{
if( DOF2_FileExists( GetPlayerArquivo( playerid ) ) )
{
Player[ playerid ][ Score ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Score");
Player[ playerid ][ Dinheiro ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Dinheiro");
Player[ playerid ][ Fundador ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Fundador");
Player[ playerid ][ Gerente ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Gerente");
Player[ playerid ][ Admin ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Admin");
Player[ playerid ][ Matou ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Matou");
Player[ playerid ][ Morreu ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Morreu");
Player[ playerid ][ Membro ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Membro"); //Linha do erro, isso
Player[ playerid ][ Cargo ] = DOF2_GetInt(GetPlayerArquivo(playerid), "Cargo"); //Linha do erro
SetPlayerScore( playerid, Player[ playerid ][ Score ] );
GivePlayerMoney( playerid, Player[ playerid] [ Dinheiro ] );
}
return 1;
}
stock SalvarPlayer(playerid)
{
new nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, nome, sizeof(nome));
format(Texto, 35, "Jogadores/%s", nome);
DOF2_FileExists(Texto);
DOF2_SetInt(Texto, "Membro", ProgressaoInfo[playerid][Membro]);
DOF2_SetInt(Texto, "Cargo", ProgressaoInfo[playerid][Cargo]);
DOF2_SaveFile();
//DOF2_Exit(); WTF??
return true;
}
|
Sobre o LoadPlayer(playerid), veirifque se voce definiu as variaveis corretamente
Код:
stock SalvarPlayer(playerid)
{
new nome[MAX_PLAYER_NAME];
GetPlayerName(playerid, nome, sizeof(nome));
format(Texto, 35, "Jogadores/%s", nome);
DOF2_FileExists(Texto);
DOF2_SetInt(Texto, "Membro", ProgressaoInfo[playerid][Membro]);
DOF2_SetInt(Texto, "Cargo", ProgressaoInfo[playerid][Cargo]);
DOF2_SaveFile();
//DOF2_Exit(); WTF??
return true;
}
|