array must be indexed (variable "PlayerInfo") array sizes do not match, or destination array is too small array must be indexed (variable "PlayerInfo") array must be indexed (variable "PlayerInfo") |
CMD:god(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 3) { if PlayerInfo[playerid]== false; { SetPlayerHealth(playerid, 99999999); SendClientMessage(playerid, COLOR_GREEN, "GodMode ON!"); PlayerInfo[playerid]= true; } else if(PlayerInfo[playerid]== true; { SetPlayerHealth(playerid, 100); SendClientMessage(playerid, COLOR_RED, "GodMode OFF!"); PlayerInfo[playerid]= false; } } else return SendClientMessage(playerid, COLOR_WHITE, "you are not authorised to use that Command"); return 1; } |
if (PlayerInfo[playerid]== false)// Your Code if PlayerInfo[playerid]== false; Wrong Definition xD
else if(PlayerInfo[playerid]== true)// Your Code else if(PlayerInfo[playerid]== true; wrong xD
PHP код:
PHP код:
|
if(PlayerInfo[playerid][pAdmin] >= 3) { if PlayerInfo[playerid]== false;
CMD:god(playerid, params[]) { if(PlayerInfo[playerid][pAdmin] >= 3) { if (PlayerInfo[playerid][pGodMode]== false) { SetPlayerHealth(playerid, 0x7FFFFFFF); SendClientMessage(playerid, COLOR_GREEN, "GodMode ON!"); PlayerInfo[playerid][pGodMode]= true; } else if(PlayerInfo[playerid][pGodMode]== true) { SetPlayerHealth(playerid, 100); SendClientMessage(playerid, COLOR_RED, "GodMode OFF!"); PlayerInfo[playerid][pGodMode]= false; } } else return SendClientMessage(playerid, COLOR_WHITE, "you are not authorised to use that Command"); return 1; }