28.10.2018, 14:23
Quote:
Which array is sized 1000?
You are accessing it with index 65535, presumibly an invalid id. |
Код:
stock ReturnName(playerid, underScore = 1) { new playersName[MAX_PLAYER_NAME + 2]; GetPlayerName(playerid, playersName, sizeof(playersName)); if(!underScore) { { for(new i = 0, j = strlen(playersName); i < j; i ++) { if(playersName[i] == '_') { playersName[i] = ' '; } } } } return playersName; } stock SendClientMessageEx(playerid, color, const str[], {Float,_}:...) { static args, start, end, string[156] ; #emit LOAD.S.pri 8 #emit STOR.pri args if (args > 12) { #emit ADDR.pri str #emit STOR.pri start for (end = start + (args - 12); end > start; end -= 4) { #emit LREF.pri end #emit PUSH.pri } #emit PUSH.S str #emit PUSH.C 156 #emit PUSH.C string #emit PUSH.C args #emit SYSREQ.C format SendClientMessage(playerid, color, string); #emit LCTRL 5 #emit SCTRL 4 #emit RETN } return SendClientMessage(playerid, color, str); }