26.05.2012, 23:22
Galera, comecei a construir um sistema basico de infoorg;(O QUE EU EU TAVA FAZENDO DEU ERRO AI DELETEI KKK).
Ai tipo. eu do /infoorg aparece Lider: e nгo aparece o nome do lider pq?
Alguem ajuda?
Ai tipo. eu do /infoorg aparece Lider: e nгo aparece o nome do lider pq?
pawn Код:
// ~> SITEMA DE INFOORG <~ //
#define MAX_ORGS (12) // Todas as orgs +1.
enum InfoO
{
Lider[MAX_PLAYER_NAME],
};
new InfoOrg[MAX_ORGS][InfoO];
LoadInfoOrg();
//INFOORG
CMD:infoorg(playerid)
{
new string[128];
new arquivo[256];
new idx = 1;
while (idx < sizeof(InfoOrg))
{
format(arquivo, sizeof(arquivo), "InfoOrg/Org%d.ini",idx);
format(string, sizeof(string), "Lider: %s", InfoOrg[idx][Lider]);
SendClientMessage(playerid, -1, string);
idx++;
}
return 1;
}
stock LoadInfoOrg()
{
new arquivo[256];
new idx = 1;
while (idx < sizeof(InfoOrg))
{
format(arquivo, sizeof(arquivo), "InfoOrg/Org%d.ini",idx);
strmid(InfoOrg[idx][Lider], DOF2_GetString(arquivo,"Lider"), 0, strlen(DOF2_GetString(arquivo,"Lider")), 255);
idx ++;
}
return 1;
}