Y_INI Error
#1

Here is the code:

pawn Код:
public LoadUser_data(playerid, name[], value[])
{
    INI_Int("Password",PlayerInfo[playerid][pPass]);
    INI_Int("Kills",PlayerInfo[playerid][pKills]);
        INI_Int("Deaths",PlayerInfo[playerid][pDeaths]);
        INI_Int("Rank",PlayerInfo[playerid][pRank]);
        INI_Int("AdminLevel",PlayerInfo[playerid][pAdminLevel]);
        INI_Int("VipLevel",PlayerInfo[playerid][pVipLevel]);
        INI_Int("Hour",PlayerInfo[playerid][pHours]);
        INI_Int("Min",PlayerInfo[playerid][pMinutes]);
        INI_Int("Sec",PlayerInfo[playerid][pSeconds]);
        INI_Int("Factionid",PlayerData[playerid][Faction]);
    INI_Int("Rank",PlayerData[playerid][Rank]);
    INI_Int("ZombieClass",PlayerInfo[playerid][pZombieClass]);
    INI_Int("IsPlayerInfected",PlayerInfo[playerid][IsPlayerInfected]);
    INI_Int("HighJumpScout",aname[playerid][HighJumpScout]);
    INI_Int("HighJumpZombie",aname[playerid][HighJumpZombie]);
    INI_Int("StomperPushing",aname[playerid][StomperPushing]);
    INI_Int("WitchAttack",aname[playerid][WitchAttack]);
    INI_Int("ScreamerZombieAb",aname[playerid][ScreamerZombieAb]);
    INI_Int("InfectionNormal",aname[playerid][InfectionNormal]);
    INI_Int("InfectionMutated",aname[playerid][InfectionMutated]);
    INI_Int("ShoutCooldown",aname[playerid][ShoutCooldown]);
    INI_Int("ScreamerZombieAb2",aname[playerid][ScreamerZombieAb2]);
    INI_Int("WitchAttack2",aname[playerid][WitchAttack2]);
    INI_Int("InjectionFleshEater",aname[playerid][InjectionFleshEater]);
    return 1;
}
The main error(s):

error 029: invalid expression, assumed zero
error 001: expected token: ";", but found "]"
error 028: invalid subscript (not an array or too many subscripts): "aname"

The lines that are the problems:

INI_Int("HighJumpScout",aname[playerid][HighJumpScout]);

This line has error 01 so usually it's the line above, which is this:

INI_Int("IsPlayerInfected",PlayerInfo[playerid][IsPlayerInfected]);

Can anyone help?
Thanks in advance
Reply
#2

Show me the enums(I see you got 3 over there)
Reply
#3

Here are the enums:

pawn Код:
enum pInfo
{
    pPass,
    pCash,
    pAdminLevel,
    pVipLevel,
    pKills,
    pDeaths,
    pReported,
    pWarnings,
    pKicks,
    pRank,
    pMuted,
    pTotalTime,
    pConnectTime,
    pHours,
    pMinutes,
    pSeconds,
    pZombieClass,
    IsPlayerInfected,
    IsPlayerInfectedTimer
}
new PlayerInfo[MAX_PLAYERS][pInfo];

enum pData
{
    Faction,
    Rank
}
new PlayerData[MAX_PLAYERS][pData];

enum aname
{
    HighJumpScout,
    HighJumpZombie,
    StomperPushing,
    WitchAttack,
    ScreamerZombieAb,
    ScreamerZombieAb2,
    InfectionNormal,
    InfectionMutated,
    ShoutCooldown,
    HealCoolDown,
    AdvancedMutatedCooldown,
    WitchAttack2,
    InfectionFleshEater
}
new Abilitys[MAX_PLAYERS][aname];
Reply
#4

Problem Resolved.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)