SA-MP Forums Archive
Help . tag mismatch - 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 . tag mismatch (/showthread.php?tid=634395)



Help . tag mismatch - ongnung147 - 18.05.2017

Код:
 warning 213: tag mismatch
 warning 213: tag mismatch
 error 032: array index out of bounds (variable "Group")
 warning 213: tag mismatch
 error 032: array index out of bounds (variable "Group")
Код:
enum ginfo 
{
     grname[255],
     leader,
     active
};
new Group[MAX_PLAYERS][pginfo];
Код:
stock LoadGroups()
{
    new FileName[128];
    for(new i = 0; i < MAX_GROUPS; i++)
    {
        format(FileName, sizeof(FileName), "Groups/Group_%d.ini", i); 
        if(fexist(FileName)) // If the file exists... 
        {
             Group[i][grname] = dini_Get(FileName, "grname"); // We use dini_Get because it is a string.
             Group[i][leader] = dini_Int(FileName, "leader"); // We use dini_Int because it is an (int)eger.
             Group[i][active] = dini_Int(FileName," active");
             printf("[system] Group %d spawned.", i); 
       }
    }
    return 1;
}



Re: Help . tag mismatch - iLearner - 18.05.2017

Quote:

enum ginfo
{
grname[255],
leader,
active
};
new Group[MAX_PLAYERS][pginfo];

4char


Re: Help . tag mismatch - ongnung147 - 18.05.2017

Код:
enum ginfo 
{
     grname[255],
     leader,
     active
};
enum pginfo
{
     gid,
     order,
     invited,
     attemptjoin
};
new Group[MAX_PLAYERS][pginfo];
new groupinfo[MAX_GROUPS][ginfo];