Hallo,
ich habe momentan ein riesen Problem bei meinen Querrys wenn ich diese nämlich speichere bei
public OnGameModeExit()
{
for(new i; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && pInfo[i][Login])
{
mysql_PlayerAccountSave(i);
}
}
print(" [SERVER] Spieler wurden gespeichert...");
mysql_BankAccountsSave();
mysql_AtmSave();
mysql_close(MySQLHandle);
return 1;
}
werden bei
mysql_BankAccountsSave();
mysql_AtmSave();
die Querrys zwar erstellt aber nicht mehr abgeschickt.
So speichere ich die Daten:
function mysql_AtmSave()
{
new query[235];
for(new i; i < MAX_ATM; i++)
{
if(atmInfo[i][Durability] > 1) {
format(query, sizeof(query), "UPDATE `db_atm` SET `CheckTime` = '%d', `RobCount` = '%d', `Money` = '%d', `Durability` = '%d', `PosX` = '%0.4f', `PosY` = '%0.4f', `PosZ` = '%0.4f', `PosZA` = '%0.4f' WHERE `id` = '%d'", \
atmInfo[i][CheckTime], atmInfo[i][RobCount], atmInfo[i][Money], atmInfo[i][Durability], atmInfo[i][atmPosX], atmInfo[i][atmPosY], atmInfo[i][atmPosZ], atmInfo[i][atmPosZA], atmInfo[i][id]);
mysql_tquery(MySQLHandle, query, "", "", "");
printf("%s", query);
}
}
print(" [SERVER] Bankautomaten wurden gespeichert...");
}
Hier der Debug:
[23:03:56] [DEBUG] mysql_format - connection: 1, len: 480, format: "%s%s, `Overdraw` = '%d', `Blocked` = '%d', `Deleteable` = '%d' WHERE `Number` = '%d'"
[23:03:56] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE `db_bank` SET `Owner` = '_BLU', `Owner2` = 'none', `Date`", callback: "(null)", format: "(null)"
[23:03:56] [DEBUG] mysql_format - connection: 1, len: 480, format: "%s%s, `Overdraw` = '%d', `Blocked` = '%d', `Deleteable` = '%d' WHERE `Number` = '%d'"
[23:03:56] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE `db_bank` SET `Owner` = 'Sammy_Schleef', `Owner2` = 'none", callback: "(null)", format: "(null)"
[23:03:56] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE `db_atm` SET (`CheckTime`, `Money`, `Durability`, `PosX`,", callback: "(null)", format: "(null)"
[23:03:56] [DEBUG] mysql_close - connection: 1
[23:03:56] [DEBUG] CMySQLConnection::Disconnect - connection was closed
[23:03:56] [DEBUG] CMySQLConnection::Disconnect - connection was closed
mfg tdXkiller