Errors in script - 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: Errors in script (
/showthread.php?tid=326497)
Errors in script -
Defence1771 - 17.03.2012
pawn Код:
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 029: invalid expression, assumed zero
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : warning 215: expression has no effect
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 001: expected token: ";", but found "]"
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 029: invalid expression, assumed zero
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : fatal error 107: too many error messages on one line
that was errors this is the line
pawn Код:
if(!IsPlayerAdmin(playerid)||PlayerInfo[playerid][AdminLevel]<5)return SendClientMessage(playerid,0xFF0000FF,"You're not authorized to use that command");
Thanks.
Re: Errors in script -
FalconX - 17.03.2012
Quote:
Originally Posted by Defence1771
pawn Код:
C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 029: invalid expression, assumed zero C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : warning 215: expression has no effect C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 001: expected token: ";", but found "]" C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : error 029: invalid expression, assumed zero C:\Users\Elias\Desktop\New folder\gamemodes\ERPS.pwn(388) : fatal error 107: too many error messages on one line
that was errors this is the line
pawn Код:
if(!IsPlayerAdmin(playerid)||PlayerInfo[playerid][AdminLevel]<5)return SendClientMessage(playerid,0xFF0000FF,"You're not authorized to use that command");
Thanks.
|
The code is wrong I guess?
try this
pawn Код:
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "You are logged in as RCON to use this command.");//this code is for, when a player is not logged in as rcon he can't use the command, he wil return the message like above.
And if you want your own admin level to be used, then try the following:-
pawn Код:
if(PlayerInfo[playerid][AdminLevel] < 5) return SendClientMessage(playerid, -1, "You are not level 5 or more to use this command."); // this code is for, when you are not level 5 in your admin system
Hope this helps
-FalconX
Re: Errors in script -
Defence1771 - 18.03.2012
ok thanks + reping you
Re: Errors in script -
Faisal_khan - 18.03.2012
Quote:
Originally Posted by Defence1771
ok thanks + reping you 
|
You cannot rep until you reach 50 posts.
Re: Errors in script -
FalconX - 22.03.2012
Quote:
Originally Posted by Defence1771
ok thanks + reping you 
|
lol, I know that you can not rep+ me but remember I don't help people for REP, it should be earned not asked for it
-FalconX