my strtok is broken (Im lost)
#1

Errors
Quote:

C:\Users\Administrator\Desktop\B3RPG\gamemodes\b3r pg.pwn(1725) : error 025: function heading differs from prototype
C:\Users\Administrator\Desktop\B3RPG\gamemodes\b3r pg.pwn(1726) : error 021: symbol already defined: "strtok"
C:\Users\Administrator\Desktop\B3RPG\gamemodes\b3r pg.pwn(1741) : error 047: array sizes do not match, or destination array is too small
C:\Users\Administrator\Desktop\B3RPG\gamemodes\b3r pg.pwn(174 : error 047: array sizes do not match, or destination array is too small
C:\Users\Administrator\Desktop\B3RPG\gamemodes\b3r pg.pwn(1752) : error 047: array sizes do not match, or destination array is too small

Problem With
Quote:

stock strtok( const string[], &index, const seperator[] = " ")
{
new
index2,
result[ 30 ];

index2 = strfind(string, seperator, false, index);


if(index2 == -1)
{
if(strlen(string) > index)
{
strmid(result, string, index, strlen(string), 30);
index = strlen(string);
}
return result;
}
if(index2 > (index + 29))
{
index2 = index + 29;
strmid(result, string, index, index2, 30);
index = index2;
return result;
}
strmid(result, string, index, index2, 30);
index = index2 + 1;
return result;
}

I need this stock or all my commands break.
Reply
#2

its probably in the inc just search alot of ppl had this problem man easy to find if u search
Reply
#3

Can you tell me which inc cause Im tried and its midnight
Reply
#4

Get some sleep. Try again tomorrow by searching all includes and filterscripts for duplicates of strtok.
Reply
#5

Wait a Sec this happened when I made 5 commands. Hmm holdon
Reply
#6

Show the commands you made, there may be a problem with them, if not, comment them out with /*
Reply
#7

Nah, they werent it but it happened when I added this filterscript into my gamemode http://forum.sa-mp.com/index.php?topic=123009.0
Ima just keep it as a filterscript until I can fix it. If anyone has any idea let me know.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)