SA-MP Forums Archive
Help - Clans not loading. - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Help - Clans not loading. (/showthread.php?tid=654099)



Help - Clans not loading. - Exhibit - 20.05.2018

Hey, I have a problem only the first clan loads and the others don't. What am I doing wrong here?
PHP код:
stock LoadClans()
{
   new 
string[80], file[64];
   for(new 
c; c < MAX_CLANS; c ++)
   {
       
format(file, sizeof(file), "Clans/%d.ini", c);
       if(
fexist(file))
       {
           
INI_ParseFile(CrewPath(c), "LoadClanData", false, true, c, true, false);
           
format(string, sizeof(string), " Loaded Clan: (%d) %s", c, CrewInfo[c][cName]);
           print(string);
           
c ++;
           
printf("\n %d clans loaded!", c);
        }
    }
   return 
true;
} 



Re: Help - Clans not loading. - kovac - 20.05.2018

PHP код:
stock LoadClans()
{
   new 
string[80], file[64], totalclans;
   for(new 
c; c < MAX_CLANS; c ++)
   {
       
format(file, sizeof(file), "Clans/%d.ini", c);
       if(
fexist(file))
       {
           
INI_ParseFile(CrewPath(c), "LoadClanData", false, true, c, true, false);
           
printf("Loaded Clan: (%i) %s", c, CrewInfo[c][cName]);
           
totalclans++;
       }
   }
   
printf("\n %i clans loaded!", totalclans);
   return 
1;
}