23.12.2015, 04:58
Hello, Can someone tell me what's wrong in this? (I didn't finish the command yet)
SCRIPT:
ERRORS:
SCRIPT:
PHP код:
CMD:ban(playerid, params[]) //line 1
{ //line 2
new ID, reason[30]; //line 3
if(pInfo[playerid][Admin] < 3) return NotAdminMSG(playerid); //line 4
if(sscanf(params, "us[30]", ID, reason)) return SCM(playerid, COLOR_WHITE, ""WORD_USAGE"/ban [PLAYER_ID] [REASON]"); //line 5
if(!IsPlayerConnected(ID)) return SCM(playerid, COLOR_WHITE, ""WORD_ERROR"This player is not connected."); //line 6
if(pInfo[playerid][Admin] < pInfo[ID][Admin]) return SCM(playerid, COLOR_WHITE, ""WORD_ERROR"You cannot apply this command on a higher admin."); //line 7
return 1; //line 8
} //line 9
Код:
C:\Program Files\MyServer\pawno\include\required/admin_commands.inc(3) : warning 219: local variable "ID" shadows a variable at a preceding level C:\Program Files\MyServer\pawno\include\required/admin_commands.inc(5) : warning 213: tag mismatch C:\Program Files\MyServer\pawno\include\required/admin_commands.inc(6) : warning 213: tag mismatch C:\Program Files\MyServer\pawno\include\required/admin_commands.inc(7) : warning 213: tag mismatch C:\Program Files\MyServer\pawno\include\required/admin_commands.inc(3) : warning 203: symbol is never used: "ID" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 5 Warnings.