01.03.2014, 10:56
Hello. I have a problem with a MySQL command. I receive this error using crashdetect:
I posted this problem some time ago, but I couldn't find a solution.
The stock I'm using:
And in my OnGameModeInit I have this:
Also, this, near the other defines:
So, what is wrong with this? I really can't figure out. I will be very grateful to anyone helps me out with this.
Код:
---------- Loaded log file: "server_log.txt". ---------- SA-MP Dedicated Server ---------------------- v0.3z, ©2005-2014 SA-MP Team [13:54:13] [13:54:13] Server Plugins [13:54:13] -------------- [13:54:13] Loading plugin: mysql [13:54:13] SA:MP MySQL Plugin v2.1.1 Loaded. [13:54:13] Loaded. [13:54:13] Loading plugin: sscanf [13:54:13] [MySQL] Thread running. Threadsafe: Yes. [13:54:13] [13:54:13] =============================== [13:54:13] sscanf plugin loaded. [13:54:13] Version: 2.8.1 [13:54:13] © 2012 Alex "******" Cole [13:54:13] =============================== [13:54:13] Loaded. [13:54:13] Loading plugin: streamer [13:54:13] *** Streamer Plugin v2.6.1 by Incognito loaded *** [13:54:13] Loaded. [13:54:13] Loading plugin: crashdetect [13:54:13] CrashDetect v4.13 is OK. [13:54:13] Loaded. [13:54:13] Loaded 4 plugins. [13:54:13] [13:54:13] Ban list [13:54:13] -------- [13:54:13] Loaded: samp.ban [13:54:13] [13:54:13] [13:54:13] Filterscripts [13:54:13] --------------- [13:54:13] Loading filterscript 'gl_realtime.amx'... [13:54:13] Loaded 1 filterscripts. [13:54:13] Houses not loaded yet. [13:54:13] 0 [13:54:13] [debug] Server crashed while executing house.amx [13:54:13] [debug] AMX backtrace: [13:54:13] [debug] #0 native mysql_query () [10007780] from mysql.DLL [13:54:13] [debug] #1 000127fc in ?? () from house.amx [13:54:13] [debug] #2 00007b98 in public SSCANF_OnGameModeInit () from house.amx [13:54:13] [debug] #3 00000654 in public zcmd_OnGameModeInit () from house.amx [13:54:13] [debug] #4 native CallLocalFunction () [00472ad0] from samp-server.exe [13:54:13] [debug] #5 00000124 in public OnGameModeInit () from house.amx [13:54:13] [debug] Native backtrace: [13:54:13] [debug] #0 100042ea in ?? () from plugins\mysql.DLL [13:54:13] [debug] #1 10007820 in ?? () from plugins\mysql.DLL [13:54:13] [debug] #2 004010b6 in ?? () from samp-server.exe [13:54:13] [debug] #3 634f58ca in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #4 634f774f in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #5 634f0834 in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #6 634f591a in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #7 00472dde in ?? () from samp-server.exe [13:54:13] [debug] #8 004010b6 in ?? () from samp-server.exe [13:54:13] [debug] #9 634f58ca in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #10 634f774f in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #11 634f0834 in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #12 634f591a in ?? () from plugins\crashdetect.DLL [13:54:13] [debug] #13 0046e624 in ?? () from samp-server.exe [13:54:13] [debug] #14 65646f6d in ?? () from samp-server.exe [13:54:13] [debug] #15 6f682f73 in ?? () from samp-server.exe [13:54:13] [debug] #16 2e657375 in ?? () from samp-server.exe [13:54:13] [debug] #17 00786d61 in ?? ()
The stock I'm using:
pawn Код:
stock MySQL_LoadHouse()
{
new savingstring[700];
print("0");
mysql_query("SELECT * FROM houses");
print("1");
mysql_store_result();
print("2");
for(new hid = 1; hid < MAX_HOUSES && mysql_fetch_row(savingstring, "|"); hid++)
{
print("3");
mysql_fetch_field("id",savingstring);
HouseInfo[hid][hId]=strval(savingstring);
print("4");
mysql_fetch_field("owner",savingstring);
strins(HouseInfo[hid][hOwner],savingstring,1);
print("5");
mysql_fetch_field("level",savingstring);
HouseInfo[hid][hLevel]=strval(savingstring);
print("6");
mysql_fetch_field("text",savingstring);
strins(HouseInfo[hid][hText],savingstring,1);
print("7");
mysql_fetch_field("renters",savingstring);
HouseInfo[hid][hRenters]=strval(savingstring);
print("8");
mysql_fetch_field("rentprice",savingstring);
HouseInfo[hid][hRentprice]=strval(savingstring);
print("9");
mysql_fetch_field("rentable",savingstring);
HouseInfo[hid][hRentable]=strval(savingstring);
print("10");
mysql_fetch_field("price",savingstring);
HouseInfo[hid][hPrice]=strval(savingstring);
print("11");
mysql_fetch_field("upgrade",savingstring);
HouseInfo[hid][hUpgrade]=strval(savingstring);
print("12");
mysql_fetch_field("locked",savingstring);
HouseInfo[hid][hLocked]=strval(savingstring);
print("13");
mysql_fetch_field("enterX",savingstring);
HouseInfo[hid][hEnterX]=strval(savingstring);
print("14");
mysql_fetch_field("enterY",savingstring);
HouseInfo[hid][hEnterY]=strval(savingstring);
print("15");
mysql_fetch_field("enterZ",savingstring);
HouseInfo[hid][hEnterZ]=strval(savingstring);
print("16");
mysql_fetch_field("exitX",savingstring);
HouseInfo[hid][hExitX]=strval(savingstring);
print("17");
mysql_fetch_field("exitY",savingstring);
HouseInfo[hid][hExitY]=strval(savingstring);
print("18");
mysql_fetch_field("exitZ",savingstring);
HouseInfo[hid][hExitZ]=strval(savingstring);
print("19");
mysql_fetch_field("interior",savingstring);
HouseInfo[hid][hInterior]=strval(savingstring);
print("20");
mysql_fetch_field("virtual",savingstring);
HouseInfo[hid][hVirtual]=strval(savingstring);
print("21");
}
mysql_free_result();
}
pawn Код:
print("Houses not loaded yet.");
MySQL_LoadHouse();
print("Houses loaded");
pawn Код:
#define MAX_HOUSES 3


