31.03.2013, 15:24
Recently I started to learn scripting.
I have a gamemode to start , but I have some errors :
This Errors:
I search on ****** and find this :
But if I put this in gamemode , The spawn is elsewhere , I fall , The teleport's dosen't work and money is on 0 and can't set money.
I wait for an answer.
Thanks a lot! ^^
I have a gamemode to start , but I have some errors :
This Errors:
Quote:
D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24632) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24632) : error 033: array must be indexed (variable "cmd") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24641) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24641) : error 033: array must be indexed (variable "x_nr") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24733) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24733) : error 033: array must be indexed (variable "x_nr") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24765) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24765) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24773) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24773) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24821) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24821) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24854) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24854) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24902) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24902) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24942) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24942) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24982) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(24982) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25052) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25052) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25241) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25241) : error 033: array must be indexed (variable "tmp") D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25302) : error 017: undefined symbol "strtok" D:\Documents and Settings\c0sminX\Desktop\samp03x_svr_R1-2_win32\gamemodes\v6.1.pwn(25302) : error 033: array must be indexed (variable "tmp") |
Код:
strtok(const stringstrtok[], &index) { new length = strlen(stringstrtok); while ((index < length) && (stringstrtok[index] <= ' ')) { index++; } new offset = index, result[20]; while ((index < length) && (stringstrtok[index] > ' ') && ((index - offset) < (sizeof(result) - 1))) { result[index - offset] = stringstrtok[index]; index++; } result[index - offset] = EOS; return result; }
I wait for an answer.
Thanks a lot! ^^