27.01.2010, 02:26
Hi, I've been trying to find this problem for a while now, I debugged the function and noticed the whole function makes the server crash (( Not just a part of it )). Anyone got an idea why it's crashing?
pawn Код:
stock LoadMaps()
{
mysql_query("SELECT * FROM `Maps`");
mysql_store_result();
new idx;
while (idx < sizeof(MapInfo))
{
mysql_fetch_row_format(resultline,"|");
split(resultline, player, '|');
MapInfo[idx][Model] = strval(player[0]);
MapInfo[idx][X] = floatstr(player[1]);
MapInfo[idx][Y] = floatstr(player[2]);
MapInfo[idx][Z] = floatstr(player[3]);
MapInfo[idx][RX] = floatstr(player[4]);
MapInfo[idx][RY] = floatstr(player[5]);
MapInfo[idx][RZ] = floatstr(player[6]);
CreateObject(MapInfo[idx][Model], MapInfo[idx][X], MapInfo[idx][Y], MapInfo[idx][Z], MapInfo[idx][RX], MapInfo[idx][RY], MapInfo[idx][RZ]);
idx++;
}
}