How to remove These errors?? (rep+) - 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: How to remove These errors?? (rep+) (
/showthread.php?tid=333424)
How to remove These errors?? (rep+) -
iOmar - 11.04.2012
pawn Код:
dcmd_offduty(playerid, params[]){
{
if(PlayerInfo[playerid][Level] >= 2)
{
CMDMessageToAdmins(playerid,"Now Off Duty"); GetPlayerName(playerid, adminname, sizeof(adminname));
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) == 1)
{
ResetPlayerWeapons(playerid);
ForceClassSelection(playerid);
SetPlayerHealth(playerid,0);
format(string,256,"Administrator %s Has End With His Admin Duty",adminname);
SendClientMessage(i,pink,string);
}
}
}
else
{
SendClientMessage(playerid,red,"ERROR: You are not a high enough level to use this command"); }
return 1;
}
return true;
}
dcmd_onduty(playerid, params[])
{
if(PlayerInfo[playerid][Level] >= 2)
{
CMDMessageToAdmins(playerid,"Now On Duty"); GetPlayerName(playerid, adminname, sizeof(adminname));
for(new i = 0; i <= MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) == 1)
{
SetPlayerSkin(playerid,217); GivePlayerWeapon(playerid,38,500000); SetPlayerHealth(playerid,100000); SetPlayerColor(playerid,pink); format(string,256,"Administrator %s Has Now On Admin Duty",adminname); SendClientMessage(i,pink,string); }
}
}
else
{
SendClientMessage(playerid,red,"ERROR: You are not a high enough level to use this command"); }
return 1;
}
}
return true;
}
=> I used this...
And i am getting These Errors:
pawn Код:
D:\Game\SA-MP Files\UnderWars\filterscripts\LuxAdmin.pwn(7141) : error 017: undefined symbol "PlayerInfo"
D:\Game\SA-MP Files\UnderWars\filterscripts\LuxAdmin.pwn(7141) : warning 215: expression has no effect
D:\Game\SA-MP Files\UnderWars\filterscripts\LuxAdmin.pwn(7141) : error 001: expected token: ";", but found "]"
D:\Game\SA-MP Files\UnderWars\filterscripts\LuxAdmin.pwn(7141) : error 029: invalid expression, assumed zero
D:\Game\SA-MP Files\UnderWars\filterscripts\LuxAdmin.pwn(7141) : fatal error 107: too many error messages on one line
Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase
4 Errors.
Re: How to remove These errors?? (rep+) -
Mark™ - 11.04.2012
post line 7141
Re: How to remove These errors?? (rep+) -
Faisal_khan - 11.04.2012
Why this error happens everytime someone convert it into dcmd?
Anyway, try adding this on the top of your script (not on the top below the defines):
pawn Код:
enum pInfo
{
pAdmin
}
new
PlayerInfo[ MAX_PLAYERS ][ pInfo ];
****** this and check out their problems they too had this error:
Код HTML:
site:forum.sa-mp.com "error 017: undefined symbol "PlayerInfo"" Lux Admin "dcmd"