27.07.2009, 12:08
Hello, I got a problem with defining strtok plus array index problem as you see:
Heres the code to that lines:
Код:
C:\GTA.DECODER.LV\gamemodes\decoder.pwn(4099) : error 017: undefined symbol "strtok" C:\GTA.DECODER.LV\gamemodes\decoder.pwn(4099) : error 033: array must be indexed (variable "cmd") Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 2 Errors.
Код:
public OnPlayerCommandText(playerid, cmdtext[]) { new cmd[256]; cmd = strtok(cmdtext, idx); // Line 4099 //------------------------------------------------------------------------------ //=====================[ TELEPORT COMMANDS ]==================================== //------------------------------------------------------------------------------ //------------------------------------------------------------------------------ if(!strcmp(cmd, "/ammunations",true) || !strcmp(cmd, "/ammunations",true)) { ShowMenuForPlayer(Ammunations,playerid); SendClientMessage(playerid, COLOR_YELLOW, "Laipni lugti municijas izvelne, izmanto lidzeklus un iegadajies ko velies."); TogglePlayerControllable(playerid, 0); return 1; }