Two errors that I dont understand -
Alex_T - 19.12.2015
Код:
LSR.pwn(194) : error 029: invalid expression, assumed zero
LSR.pwn(194) : error 008: must be a constant expression; assumed zero
Код:
enum AdminInfo {
AdminLevel, //flag ID
AdminLevelDesc[64],//description of admin flag
};
new AdminFlagDescription[][AdminInfo] =
{
{0, "Nothing"},
{1, "Something"},
{2, "Moderator"},
{3, "Trial Moderator"},
{4, "Moderator"},
{5, "Administrator"},
{6, "Refund Admin"},
{7, "Head Admin"},
{8, "Lead Admin"},
{9, "Co-Founder"},
{10, "Founder"}
};
enum EAdminCmds {
ECmdName[32],
ECmdNewbLevel,
AdminLevel, //bitmask which must be matched
ECmdMinConnectTime,
ECmdMaxConnectTime, //n
ECmdMinLevel, //votekick, etc
};
new admincmds[][EAdminCmds] = {
{"goto", 2, 1,0, 0, 0},
{"gethere", 2, 1,0, 0, 0},
{"destroyplayercar", 2, 7,0, 0, 0},
{"createplayercar", 2, 7,0, 0, 0},
{"checkip", 2, 1,0, 0, 0},
{"ahide", 2, 3,0, 0, 0},
{"kick", 2, 1,0, 0, 0},
{"ban", 2, 1,0, 0, 0},
{"unban", 2, 1,0, 0, 0},
{"poke", 2, 1,0, 0, 0},
{"makeadmin", 2, 7,0, 0, 0},
{"a", 2, 1,0, 0, 0},
{"setadmintitle", 2, 5,0, 0, 0},
{"id", 2, 2,0, 0, 0},
{"aduty", 2, 1,0, 0, 0},
{"getcar", 2, 1,0, 0, 0},
{"gotov", 2, 1,0, 0, 0},
{"respawnv", 2, 1,0, 0, 0},
{"freeze", 2, 1,0, 0, 0},
{"setskin", 2, 1,0, 0, 0},
{"restartserver", 2, 7,0, 0, 0},
{"check", 2, 1,0, 0, 0},
{"setworld", 2, 1,0, 0, 0},
{"gotols", 2, 1,0, 0, 0},
{"agivelicense", 2, 5,0, 0, 0},
};/*Line 194*/
Re: Two errors that I dont understand -
Infinity001 - 19.12.2015
Remove the ;
Re: Two errors that I dont understand -
Alex_T - 19.12.2015
Got these errors now
Код:
LSR.pwn(194) : error 029: invalid expression, assumed zero
LSR.pwn(194 -- 196) : error 008: must be a constant expression; assumed zero
Re: Two errors that I dont understand -
SickAttack - 19.12.2015
The last list element must not have a comma on it (last character).
pawn Код:
enum AdminInfo {
AdminLevel,
AdminLevelDesc[64]
};
new AdminFlagDescription[][AdminInfo] =
{
{0, "Nothing"},
{1, "Something"},
{2, "Moderator"},
{3, "Trial Moderator"},
{4, "Moderator"},
{5, "Administrator"},
{6, "Refund Admin"},
{7, "Head Admin"},
{8, "Lead Admin"},
{9, "Co-Founder"},
{10, "Founder"}
};
enum EAdminCmds {
ECmdName[32],
ECmdNewbLevel,
AdminLevel,
ECmdMinConnectTime,
ECmdMaxConnectTime,
ECmdMinLevel
};
new admincmds[][EAdminCmds] = {
{"goto", 2, 1,0, 0, 0},
{"gethere", 2, 1,0, 0, 0},
{"destroyplayercar", 2, 7,0, 0, 0},
{"createplayercar", 2, 7,0, 0, 0},
{"checkip", 2, 1,0, 0, 0},
{"ahide", 2, 3,0, 0, 0},
{"kick", 2, 1,0, 0, 0},
{"ban", 2, 1,0, 0, 0},
{"unban", 2, 1,0, 0, 0},
{"poke", 2, 1,0, 0, 0},
{"makeadmin", 2, 7,0, 0, 0},
{"a", 2, 1,0, 0, 0},
{"setadmintitle", 2, 5,0, 0, 0},
{"id", 2, 2,0, 0, 0},
{"aduty", 2, 1,0, 0, 0},
{"getcar", 2, 1,0, 0, 0},
{"gotov", 2, 1,0, 0, 0},
{"respawnv", 2, 1,0, 0, 0},
{"freeze", 2, 1,0, 0, 0},
{"setskin", 2, 1,0, 0, 0},
{"restartserver", 2, 7,0, 0, 0},
{"check", 2, 1,0, 0, 0},
{"setworld", 2, 1,0, 0, 0},
{"gotols", 2, 1,0, 0, 0},
{"agivelicense", 2, 5,0, 0, 0}
};