Help Me! Two Lame Error's!!!
#1

Error's:
Код:
C:\Users\Slashas94\Desktop\Sona GM\gamemodes\Sona.pwn(1361) : error 021: symbol already defined: "strtok"
C:\Users\Slashas94\Desktop\Sona GM\gamemodes\Sona.pwn(1376) : error 047: array sizes do not match, or destination array is too small
Line's:
Код:
public OnPlayerExitedMenu(playerid)
{
	return 1;
}

stock 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;
}
Please help me, i can't fix it!
Reply
#2

try to put the stock under ongamemodeinit. Not in but below it.
Reply
#3

where do you see such a line with ONGAMEMODEINIT? i've tried to delete it but PAWNO crashes!
Reply
#4

Delete it away
Reply
#5

i've tried, but if i delete it PAWN crashes
Reply
#6

can you send me your script in PM?
With pastebin
Reply
#7

come on! can someone help me?
Reply
#8

Can you paste your #includes please? Thanks...

Also, I want them because if you have the latest 0.7 includes, a_samp includes utils which already has strtok defined so you don't need it in your script.

Secondly, with the ExitedMenu, I can't see anything wrong so if you're not using it, delete it ^.^
Reply
#9

I Can't Delete STRTOCK! I SAID PAWN CRASHES IF I DELETE IT
Reply
#10

I pmed you the goo done
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)