if(dini_Isset("Avisos.ini",PlayerName(Avisos))) AvisosSalvar(playerid,dini_Int("Avisos.ini",PlayerName(playerid)));
error 017: undefined symbol "Avisos" error 017: undefined symbol "AvisosSalvar" |
public OnPlayerConnect(playerid)
{
if(dini_Isset("Avisos.ini",PlayerNameDKN(Avisos))) AvisosSalvar(playerid,dini_Int("Avisos.ini",PlayerNameDKN(playerid)));
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
new cmd[128];
if(strcmp(cmd, "/adv", true) == 0)
{
new tmp[128];
if(strlen(tmp) == 0) return SendClientMessage(playerid, 0xFFFFFFFF, "Uso do Comando: /advertencia");
new year, month, day;
getdate(year, month, day);
SendClientMessage(playerid,0xAFAFAFAA,"Player Advertido com Sucesso");
GameTextForPlayer(strval(tmp), "~r~Nгo Repita Isso ou Serб Punido Severamente", 5000, 1);
new name[MAX_PLAYER_NAME], string[44];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s foi Advertido por Motivos Internos da Administraзгo .",name);
SendClientMessageToAll(0xFFFF00AA, string);return 1;
}
return 1;
}
error 017: undefined symbol "AvisosSalvar" error 017: undefined symbol "Avisos" |
Avisos
AvisosSalvar
Originally Posted by andmeida10
vc n definiu o
pawn Код:
pawn Код:
|
forward AvisosDKN(string[]);
enum aAcc
{
aAvisosDraKoN,
aLogged,
}
new DraKoNWarns[MAX_PLAYERS][aAcc];
forward WarnPlayerDKN(playerid);
public WarnPlayerDKN(playerid)
{
if(IsPlayerConnected(playerid))
{
new name[MAX_PLAYER_NAME], str[128];
GetPlayerName(playerid, name, sizeof name);
format(str, sizeof str, "%s.ini", name);
new File:account = fopen(str, io_write);
if (account)
{
new file[128];
{
format(file, sizeof file, "Avisos: %d\n", DraKoNWarns[playerid][aAvisosDraKoN]);
}
fclose(account);
SendClientMessage(playerid, 0x21DD00FF, "A Partir de Agora Seus Avisos Serгo Salvos.");
}
}
return 1;
}
forward SavePlayerDKN(playerid);
public SavePlayerDKN(playerid)
{
if(IsPlayerConnected(playerid))
{
if(DraKoNWarns[playerid][aLogged] == 1)
{
new name[MAX_PLAYER_NAME], str[128];
GetPlayerName(playerid, name, sizeof name);
format(str, sizeof str, "%s.ini", name);
new File:account = fopen(str, io_write);
if (account)
{
new file[128];
{
format(file, sizeof file, "Avisos: %d\n",DraKoNWarns[playerid][aAvisosDraKoN]);
{ fwrite(account, file); }
}
fclose(account);
}
}
}
return 1;
}
new cmd[128];
if(strcmp(cmd, "/adv", true) == 0)
{
new tmp[128];
if(strlen(tmp) == 0) return SendClientMessage(playerid, 0xFFFFFFFF, "Uso do Comando: /advertencia");
new year, month, day;
getdate(year, month, day);
SendClientMessage(playerid,0xAFAFAFAA,"Player Advertido com Sucesso");
GameTextForPlayer(strval(tmp), "~r~Nгo Repita Isso ou Serб Punido Severamente", 5000, 1);
new name[MAX_PLAYER_NAME], string[44];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s foi Advertido por Motivos Internos da Administraзгo .",name);
SendClientMessageToAll(0xFFFF00AA, string);return 1;
}
SavePlayerDKN(playerid);// Aqui irб Usar a Public para Salvar xD
DraKoNWarns[strval(tmp)][aAvisosDraKoN] ++;//Ira Adicionar o Aviso no Arquivo
return 1;
}
Originally Posted by SuB_ZeRo0_
Isso era mais fбcil com DUDB.
Mas ai o sistema de registro teria que ser em DUDB. =/ |