Split problem
#1

Код:
				new money;
				new score;
				new nick[250];
				
				new resultline[512];
				
				mysql_fetch_row_format(resultline);
				new tmp[2][14];
				split(resultline, tmp, "|");
				nick = tmp[0];
				Info[playerid][Pass] = tmp[1];
				Info[playerid][Adminlevel] = tmp[2];
			    money = tmp[3];
				score = tmp[3];
				Info[playerid][Kills] = tmp[4];
				Info[playerid][Deaths] = tmp[5];
				Info[playerid][Mutato] = tmp[6];
				Info[playerid][Warnato] = tmp[7];
				Info[playerid][Loggato] = tmp[8];
				Info[playerid][Bannato] = tmp[9];
				Info[playerid][Cmdblock] = tmp[10];
				Info[playerid][PEuro] = tmp[11];
				Info[playerid][PSkin] = tmp[12];
SPLIT CODE

Код HTML:
stock split(const strsrc[], strdest[][], delimiter)
{
    new i, li;
    new aNum;
    new len;
    while(i <= strlen(strsrc))
    {
        if(strsrc[i] == delimiter || i == strlen(strsrc))
        {
            len = strmid(strdest[aNum], strsrc, li, i, 128);
            strdest[aNum][len] = 0;
            li = i+1;
            aNum++;
        }
        i++;
    }
    return 1;
}
ERROR:
Код HTML:
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7579) : error 035: argument type mismatch (argument 3)
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7581) : error 047: array sizes do not match, or destination array is too small
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7582) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7582) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7583) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7583) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7584) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7584) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7585) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7585) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7586) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7586) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7587) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7587) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7588) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7588) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7589) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7589) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7590) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7590) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7591) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7591) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7592) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7592) : error 006: must be assigned to an array
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7593) : error 032: array index out of bounds (variable "tmp")
C:\Users\Andrea\Desktop\Cartelle\IbP\gamemodes\CwS.pwn(7593) : error 006: must be assigned to an array
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)