Jump to content

Question

Posted

C:\Documents and Settings\BogdaneL\My Documents\sa-mp\samp03\gamemodes\HGZ.pwn(C:\Documents and Settings\BogdaneL\My Documents\sa-mp\samp03\gamemodes\HGZ.pwn(10045) : error 021: symbol already defined: "strtok"
C:\Documents and Settings\BogdaneL\My Documents\sa-mp\samp03\gamemodes\HGZ.pwn(10060) : error 047: array sizes do not match, or destination array is too small
C:\Documents and Settings\BogdaneL\My Documents\sa-mp\samp03\gamemodes\HGZ.pwn(11893) : warning 219: local variable "mod" shadows a variable at a preceding level
Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase
10045 -
{
10060
return result;
Asta reprezinta:
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;
}
Linia 11893 si 11893
				new mod = 100;
				tmp = strtok(cmdtext, idx);

Ce trebuie sa fac sa nu imi apare erorile astea?

LISTA - GAMEMODE-URI SA-MP - Le gasiti pe toate aici: http://twiriock.com/3MGP

1 answer to this question

Recommended Posts

Posted

Sterge

[pawn]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;

}[/pawn]

E deja definit.

Sterge si new mod = 100;

Nu mai posta erori din pwn la ajutor servere!

Lock!

gXvsYS
Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.