SA-MP Forums Archive
[Ajuda] Problemas com strtok - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Português/Portuguese (https://sampforum.blast.hk/forumdisplay.php?fid=34)
+---- Thread: [Ajuda] Problemas com strtok (/showthread.php?tid=574300)



Problemas com strtok - Review - 15.05.2015

D:\GM\gamemodes\new.pwn(3291) : warning 204: symbol is assigned a value that is never used: "pPos"
D:\GM\gamemodes\new.pwn(3580) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(3580) : error 033: array must be indexed (variable "cmd")
D:\GM\gamemodes\new.pwn(3929) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\\new.pwn(3929) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4207) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4207) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4219) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4219) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4443) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4443) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4470) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4470) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4496) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4496) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4540) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4540) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4731) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4731) : error 033: array must be indexed (variable "x_nr")
D:\GM\gamemodes\new.pwn(4883) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4883) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(4937) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(4937) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(5086) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(5086) : error 033: array must be indexed (variable "tmp")
D:\GM\gamemodes\new.pwn(5171) : error 017: undefined symbol "strtok"
D:\GM\gamemodes\new.pwn(5171) : error 033: array must be indexed (variable "tmp")


Re: Nessecito de HELP - Whoo - 15.05.2015

PHP код:
strtok(const string[], &index)
{
    new 
length strlen(string);
    while ((
index length) && (string[index] <= ' '))
    {
        
index++;
    }
 
    new 
offset index;
    new 
result[20];
    while ((
index length) && (string[index] > ' ') && ((index offset) < (sizeof(result) - 1)))
    {
        
result[index offset] = string[index];
        
index++;
    }
    
result[index offset] = EOS;
    return 
result;




Respuesta: Nessecito de HELP - Review - 15.05.2015

Funciono vlw , mais deu 23 erros que agora vo tentar arrumar.

@Edit esqueci +REP


Re: Respuesta: Nessecito de HELP - Vegassilva - 15.05.2015

Quote:
Originally Posted by Review
Посмотреть сообщение
Funciono vlw , mais deu 23 erros que agora vo tentar arrumar.

@Edit esqueci +REP
Quando da 23 erros, Й por que vocк esqueceu de por alguma chave ver ai no comando ou callback ...


Re: Respuesta: Nessecito de HELP - PT - 15.05.2015

Quote:
Originally Posted by Vegassilva
Посмотреть сообщение
Quando da 23 erros, Й por que vocк esqueceu de por alguma chave ver ai no comando ou callback ...
26*

nao 23 xD


Re: Problemas com strtok - JkS - 16.05.2015

STRTOK jб й muita velhinha, minha dica й vocк utilizar SSCANF.


Re: Problemas com strtok - PT - 16.05.2015

Da uma olhada: https://sampforum.blast.hk/showthread.php?tid=493276 e https://sampforum.blast.hk/showthread.php?tid=460056