29/05/2020, 08:18 AM   #3
 Originally Posted by Ertouq Recently on my server I discovered this: PHP Code: ``` [18:31:24] [debug] Run time error 4: "Array index out of bounds" [18:31:24] [debug]  Attempted to read/write array element at index 65535 in array of size 1000 [18:31:24] [debug] AMX backtrace: [18:31:24] [debug] #0 00063208 in main (playerid=0, params[]=@006e9c2c "2 0") at C:\Users\ert\OneDrive\Escritorio\sv\gamemodes\sv.pwn:3621  ``` and the command: PHP Code: ``` CMD:sethealth(playerid, params[]) {     new id, Float:health, string[124];     if(sscanf(params, "uf", id, health)) return SendClientMessage(playerid, -1, "/sethealth (id/name)");     if(PlayerInfo[playerid][Admin] < 2) return 0;     if(PlayerInfo[id][Logged] == 0) return SendClientMessage(playerid, -1, "this player is not logged yet");     format(string, sizeof(string), "Admin %s has changed your health to %0.1f.", GetName(playerid), health);     SendClientMessage(id, 0x1153EEFF, string);     SetPlayerHealth(id, health);     return 1; }  ``` I've tried to change but it doesn't work. Thanks!
``` CMD:sethealth(playerid, params[]) {     if(PlayerInfo[playerid][Admin] < 2) return 0;     new id, Float:health, string[124];     if(sscanf(params, "uf", id, health)) return SendClientMessage(playerid, -1, "/sethealth (id/name) (health)");     if(!IsPlayerConnected(id)) return SendClientMessage(playerid, -1, "this player is not connected yet");     if(PlayerInfo[id][Logged] == 0) return SendClientMessage(playerid, -1, "this player is not logged yet");     format(string, sizeof(string), "Admin %s has changed your health to %0.1f.", GetName(playerid), health);     SendClientMessage(id, 0x1153EEFF, string);     SetPlayerHealth(id, health);     return 1; }  ```