Registrieren/Login-System und Spieler Speichern geht nicht Spielercars werden nicht da gespeichert wo sie sein sollen?

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Guten Morgen


    Ich habe gestern gemerkt das beim Registrieren die Werte zwar übergeben werden aber nach dem Logout nicht so ganz gespeichert werdern.
    Sobald man sich wieder Einloggt sind die werte wie: Geld,Level,Adminlevel,Fraktion,Rang und Spawnchange auf 0



    Mein Code sieht wie folgt aus:
    #define DIALOG_REGISTER
    #define DIALOG_LOGIN
    forward carSavedToDB(carid);
    forward OnPlayerCarsLoad(playerid);


    enum playerInfo{
    eingeloggt,
    level,
    db_id,
    alevel,
    fraktion,
    rang,
    spawnchange
    }


    enum autoEnum{
    id_x,
    model,
    besitzer,
    Float:c_x,
    Float:c_y,
    Float:c_z,
    Float:c_r,
    db_id
    }


    new sInfo[MAX_PLAYERS][playerInfo];


    new aInfo[50][autoEnum];


    //mysql:
    #define db_host "85.190.160.205"
    #define db_user "ni515543_2_DB"
    #define db_pass "xxxxxxx"
    #define db_db "ni515543_2_DB"
    new dbhandle;


    public OnGameModeExit()
    {
    mysql_close(dbhandle);
    }


    public OnUserCheck(playerid)
    {
    new num_rows,num_fields;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==0)
    {
    //Register
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Account Erstellung","Gebe bitte nun dein gewünschtes Passwort ein!","Registrieren","Abbrechen");
    }
    else
    {
    //Login
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Anmelden","Gebe bitte dein Passwort ein.","Anmleden","Abbrechen");
    }
    return 1;
    }


    public OnPlayerConnect(playerid)
    {
    if(IsPlayerNPC(playerid)) return 1;
    new nachricht[128];
    format(nachricht,sizeof(nachricht),"Du bist mit der ID %i verbunden.",playerid);
    SendClientMessage(playerid,rot,nachricht);
    //Login/Register:
    new name[MAX_PLAYER_NAME],query[128];
    GetPlayerName(playerid,name,sizeof(name));
    format(query,sizeof(query),"SELECT id FROM user WHERE username='%s' ",name);
    mysql_function_query(dbhandle,query,true,"OnUserCheck","i",playerid);
    SendClientMessage(playerid,grün,"Willkommen auf Reallife Version 0.1.4! Wir wünschen euch ein angenehmen Spiel spaß bei uns!");
    //textdraws anzeigen:
    TextDrawShowForPlayer(playerid,Text:uhrzeitLabel);
    TextDrawShowForAll(Jahr);
    SetPlayerColor(playerid,weiß);
    sInfo[playerid][level]=1;
    SetPlayerScore(playerid,sInfo[playerid][level]);
    return 1;
    }


    savePlayer(playerid)
    {
    if(sInfo[playerid][eingeloggt]==0)return 1;
    //Speichern level,money
    new query[256];
    format(query,sizeof(query),"UPDATE user SET level='%i',money='%i',alevel='%i',fraktion='%i,rang='%i',spawnchange='%i' WHERE id='%i'",sInfo[playerid][level],GetPlayerMoney(playerid),sInfo[playerid][alevel],sInfo[playerid][fraktion],sInfo[playerid][rang],sInfo[playerid][spawnchange],sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,false,"","");
    return 1;
    }
    resetPlayer(playerid)
    {
    for(new i=0; i<sizeof(sInfo[]); i++)
    {
    sInfo[playerid][playerInfo:i]=0;
    }
    return 1;
    }
    public OnPlayerDisconnect(playerid, reason)
    {
    for(new i=0; i<sizeof(aInfo); i++)
    {
    if(aInfo[i][id_x]==0)continue;
    if(aInfo[i][besitzer]!=sInfo[playerid][db_id])continue;
    GetVehiclePos(aInfo[i][id_x],aInfo[i][c_x],aInfo[i][c_y],aInfo[i][c_z]);
    GetVehicleZAngle(aInfo[i][id_x],aInfo[i][c_r]);
    new query[156];
    format(query,sizeof(query),"UPDATE user SET level='%i',money='%i',alevel='%i',fraktion='%i,rang='%i' WHERE id='%i'",sInfo[playerid][level],
    GetPlayerMoney(playerid),sInfo[playerid][alevel],sInfo[playerid][fraktion],sInfo[playerid][rang],sInfo,sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,false,"","");
    DestroyVehicle(aInfo[i][id_x]);
    aInfo[i][id_x]=0;
    break;
    }
    savePlayer(playerid);
    resetPlayer(playerid);
    loadPlayerCars(playerid);
    return 1;
    }


    public carSavedToDB(carid)
    {
    aInfo[carid][db_id]=cache_insert_id(dbhandle);
    return 1;
    }


    saveCarToDB(playerid,carid)
    {
    new query[128];
    format(query,sizeof(query),"INSERT INTO autos(besitzer,model,x,y,z,r) VALUES('%i','%i','%f','%f','%f','%f')",sInfo[playerid][db_id],aInfo[carid][model],aInfo[carid][c_x],aInfo[carid][c_y],aInfo[carid][c_z],aInfo[carid][c_r]);
    mysql_function_query(dbhandle,query,true,"carSavedToDB","i",carid);
    return 1;
    }
    createPlayerCar(playerid,modelid,Float:x,Float:y,Float:z,Float:r)
    {
    for(new i=0; i<sizeof(aInfo); i++)
    {
    if(aInfo[i][id_x]!=0)continue;
    aInfo[i][besitzer]=sInfo[playerid][db_id];
    aInfo[i][c_x] =x;
    aInfo[i][c_y] =y;
    aInfo[i][c_z] =z;
    aInfo[i][c_r] =r;
    aInfo[i][model] =modelid;
    aInfo[i][id_x] = CreateVehicle(modelid,x,y,z,r,-1,-1,-1);
    new string[128];
    format(string,sizeof(string),"Das Auto aInfo[%i]wurde erstellt",i);
    SendClientMessageToAll(duneklhelblau,string);
    saveCarToDB(playerid,i);
    return 1;
    }
    return 1;
    }
    ocmd:spawnchange(playerid,params[])
    {
    if(isPlayerInFrakt(playerid,0)) return SendClientMessage(playerid,rot,"Du bist in keiner Fraktion.");
    if(sInfo[playerid][spawnchange] == 0)
    {
    sInfo[playerid][spawnchange] = 1;
    }
    else
    {
    sInfo[playerid][spawnchange] = 0;
    }
    savePlayer(playerid);
    SendClientMessage(playerid,grün,"Spawn geändert");
    return 1;
    } für die Fraktionen!


    ocmd:einladen(playerid,params[])
    {
    if(isPlayerInFrakt(playerid, 0))return SendClientMessage(
    playerid, helblau, "Du bist in keiner Fraktion.");
    if(sInfo[playerid][rang] < 6)return SendClientMessage(
    playerid, helblau, "Dein Rang ist zu niedrig.");
    new pID, fID;
    fID = sInfo[playerid][fraktion];
    if(sscanf(params, "u", pID))return SendClientMessage(
    playerid, gelb, "INFO: /invite [playerid]");
    if(!isPlayerInFrakt(pID, 0))return SendClientMessage(
    playerid, gelb, "Spieler ist kein Zivilist.");
    new string[128];
    format(string,sizeof(string), "%s hat dich in die Fraktion %s eingeladen.",
    getPlayerName(playerid), fInfo[fID][f_name]);
    SendClientMessage(pID, gelb, string);
    SendClientMessage(pID, gelb,
    "Zum akzeptieren /accept invite eingeben.");
    SetPVarInt(pID, "inv_fraktid", fID);
    SetPVarInt(pID, "inv_inviter", playerid);
    return 1;
    }
    ocmd:annehmen(playerid, params[])
    {
    new item[64];
    if(sscanf(params,"s[64]",item))return SendClientMessage(
    playerid, gelb, "INFO: /accept [invite]");
    if(!strcmp(item, "invite", false))
    {
    if(GetPVarInt(playerid, "inv_fraktid") == 0)return SendClientMessage(
    playerid, grün, "Du wurdest in keine Fraktion eingeladen.");
    new fID = GetPVarInt(playerid, "inv_fraktid");
    sInfo[playerid][fraktion] = fID;
    sInfo[playerid][rang] = 1;
    new string[128];
    format(string,sizeof(string), "Du bist der Fraktion %s beigetreten.",
    fInfo[fID][f_name]);
    SendClientMessage(playerid, grün, string);
    format(string,sizeof(string), "%s ist der Fraktion beigetreten.",
    getPlayerName(playerid));
    SendClientMessage(GetPVarInt(playerid, "inv_inviter"), grün,
    string);
    SetPVarInt(playerid, "inv_fraktid", 0);
    return 1;
    }
    return 1;
    }


    ocmd:Leadererstellen(playerid,params[])
    {
    if(!isAdmin(playerid,5))return SendClientMessage(playerid,grün,"Du hast keine Berechtigung dazu!");
    new pID, fID;
    if(sscanf(params,"ui",pID,fID))return SendClientMessage(playerid,rot,"INFO: /Leadererstellen[playerid][fraktid]");
    if(fID>= sizeof(fInfo))return SendClientMessage(playerid,rot,"Fraktion existiert nicht.");
    sInfo[pID][fraktion] = fID;
    sInfo[pID][rang] = 6;
    new string[128];
    format(string,sizeof(string),"%s hat dich zum Leader der Fraktion %s gemacht",getPlayerName(playerid),fInfo[fID][f_name]);
    SendClientMessage(pID,gelb,string);
    SendClientMessage(playerid,grün,"Du hast einen Spieler zum Leader gemacht.");


    return 1;
    }


    ocmd:autoentfernen(playerid, params[])
    {
    new vID = GetPlayerVehicleID(playerid);
    if(!IsPlayerInAnyVehicle(playerid))return SendClientMessage(playerid, hellgrün, "Du bist in kein Auto!");
    for (new i = 0; i < sizeof(aInfo); i++)
    {
    if(vID == aInfo[i] [id_x])
    {
    if(!strcmp(aInfo[i][besitzer], SpielerName(playerid)))
    {
    new query[128];
    format(query, sizeof(query), "DELETE FROM autos WHERE id='%i'",aInfo[i][db_id]);
    mysql_function_query(dbhandle,query,false," "," ");
    DestroyVehicle(aInfo[i][besitzer]);
    aInfo[i] [id_x] = 0;
    SendClientMessage(playerid, hellgrün, "Du hast dein Auto entfernt.");
    return 1;
    }
    break;
    }
    }
    return SendClientMessage(playerid, hellgrün, "Du sitzt nicht in deinem Auto!");
    }


    ocmd:adminerstellen(playerid,params[])
    {
    if(!isAdmin(playerid,6))
    return SendClientMessage(playerid,grün,"Dein Adminrang ist nicht hochgenug!");
    new pID,a_level;
    if(sscanf(params,"ui",pID,a_level))
    return SendClientMessage(playerid,dunkelblau,"INFO: /adminerstellen [playerid][adminleve]");
    sInfo[pID][alevel]=a_level;
    savePlayer(pID);
    SendClientMessage(pID,helblau,"Sie wurden erfolgreich befördert!");
    SendClientMessage(playerid,helblau,"Du hast den Adminrang geändert!");
    return 1;
    }


    public OnPlayerCarsLoad(playerid)
    {
    new num_fields,num_rows;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(!num_rows)return 1;
    for(new i=0; i<num_rows; i++)
    {
    new id=getFreeCarID();
    aInfo[id][model]=cache_get_field_content_int(i,"model",dbhandle);
    aInfo[id][besitzer]=cache_get_field_content_int(i,"besitzer",dbhandle);
    aInfo[id][c_x]=cache_get_field_content_float(i,"x",dbhandle);
    aInfo[id][c_y]=cache_get_field_content_float(i,"y",dbhandle);
    aInfo[id][c_z]=cache_get_field_content_float(i,"z",dbhandle);
    aInfo[id][c_r]=cache_get_field_content_float(i,"r",dbhandle);
    aInfo[id][db_id]=cache_get_field_content_int(i,"id",dbhandle);
    aInfo[id][id_x]=CreateVehicle(aInfo[id][model],aInfo[id][c_x],aInfo[id][c_y],aInfo[id][c_z],aInfo[id][c_r],-1,-1,-1);
    }
    return 1;
    }


    loadPlayerCars(playerid)
    {
    new query[128];
    format(query,sizeof(query),"SELECT * FROM autos WHERE besitzer='%i'",sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,true,"OnPlayerCarsLoad","i",playerid);
    return 1;
    }


    public OnPasswordResponse(playerid)
    {
    new num_rows,num_fields;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(num_rows==1)
    {
    //passwort Richtig
    sInfo[playerid][eingeloggt] = 1;
    sInfo[playerid][level] = cache_get_field_content_int(0,"level",dbhandle);
    SetPlayerScore(playerid,sInfo[playerid][level]);
    sInfo[playerid][db_id] = cache_get_field_content_int(0,"id",dbhandle);
    SetPlayerMoney(playerid,cache_get_field_content_int(0,"money",dbhandle));
    sInfo[playerid][alevel] = cache_get_field_content_int(0,"alevel",dbhandle);
    sInfo[playerid][fraktion] = cache_get_field_content_int(0,"fraktion",dbhandle);
    sInfo[playerid][rang] = cache_get_field_content_int(0,"rang",dbhandle);
    sInfo[playerid][spawnchange] = cache_get_field_content_int(0,"spawnchange",dbhandle);
    SetPlayerScore(playerid,sInfo[playerid][level]);
    loadPlayerCars(playerid);


    }
    else
    {
    //Passwort Falsch
    SendClientMessage(playerid,grün,"Du hast dein Passwort falsch eingetippt. Versuche es nochmal!");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Login","Gibt bitte dein Passwort ein:","Anmelden","Abbrechen");
    }
    return 1;
    }


    Dialoge:
    if(dialogid==DIALOG_LOGIN)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>0)
    {
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"SELECT * FROM user WHERE username='%s' AND passwort=MD5('%s')",name,passwort);
    mysql_function_query(dbhandle,query,true,"OnPasswordResponse","i",playerid);
    }
    else
    {
    //Keine Eingabe
    SendClientMessage(playerid,grün,"Gibt bitte dein Passwort ein.");
    ShowPlayerDialog(playerid,DIALOG_LOGIN,DIALOG_STYLE_PASSWORD,"Login","Gibt bitte dein Passwort ein:","Anmelden","Abbrechen");
    }
    }
    else
    {
    Kick(playerid);
    }
    }
    if(dialogid==DIALOG_REGISTER)
    {
    if(response)
    {
    new name[MAX_PLAYER_NAME],query[128],passwort[35];
    GetPlayerName(playerid,name,sizeof(name));
    if(strlen(inputtext)>5)
    {
    //Registrierungsfunktion
    mysql_escape_string(inputtext,passwort,dbhandle);
    format(query,sizeof(query),"INSERT INTO user (username,passwort) VALUES ('%s',MD5('%s')) ",name,passwort);
    mysql_function_query(dbhandle,query,false,"","");
    sInfo[playerid][level]=1;
    SetPlayerScore(playerid,sInfo[playerid][level]);
    }
    else
    {
    //Kleiner als 4 Zeichen
    SendClientMessage(playerid,helblau,"Dein Passwort muss mindestens 6 Zeichen lang sein.");
    ShowPlayerDialog(playerid,DIALOG_REGISTER,DIALOG_STYLE_INPUT,"Account Erstellung","Gebe bitte nun dein gewünschtes Passwort ein!","Erstellen","Abbrechen");
    }
    }
    else
    {
    Kick(playerid);
    }
    }


    if(dialogid== DIALOG_Autosystem)
    {
    if(response)
    {
    if(listitem==0)
    {
    if(!IsPlayerInAnyVehicle(playerid))return
    SendClientMessage(playerid,rot,"Sie sind nicht im Fahrzeug");
    //motorfunktion
    if(GetPlayerState(playerid)!=PLAYER_STATE_DRIVER)
    {
    SendClientMessage(playerid,blau,"Sie sind nicht der Fahrer dieses Fahrzeuges");
    }
    new vID=GetPlayerVehicleID(playerid), motor, licht, alarm, tueren, bonnet, boot, objective;
    //Motor an/ausschalten:
    GetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    if(motor==1) motor = 0;
    else motor = 1;
    SetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    SendClientMessage(playerid,blau,"Sie haben den Motor Ihres Fahrzeuges angeschlaten/ausgeschalten!");
    }
    }
    if(listitem==1)
    {
    if(!IsPlayerInAnyVehicle(playerid))return
    SendClientMessage(playerid,rot,"Sie sind nicht im Fahrzeug");
    if(GetPlayerState(playerid)!=PLAYER_STATE_DRIVER)
    return SendClientMessage(playerid,blau,"Sie befinden sich nicht in Ihr Fahrzeug");
    new vID=GetPlayerVehicleID(playerid),
    motor,
    licht,
    alarm,
    tueren,
    bonnet,
    boot,
    objective;
    //licht an/ausschalten:
    GetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    if(licht==1){
    licht = 0;
    }
    else
    {
    licht = 1;
    }
    SetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    SendClientMessage(playerid,blau,"Du hast das Licht an eingeschalten/ausgeschalten");
    }
    if(listitem==2)
    {
    new motor,
    licht,
    alarm,
    tueren,
    bonnet,
    boot,
    objective;


    new vID = INVALID_VEHICLE_ID;
    if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
    {
    new Float:Pos[3];
    for(new i=0;i<MAX_VEHICLES; i++)
    {
    GetVehiclePos(i, Pos[0], Pos[1], Pos[2]);
    if(IsPlayerInRangeOfPoint(playerid, 5.0, Pos[0], Pos[1], Pos[2]))
    {
    vID = i;
    break;
    }
    }
    }
    else if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
    {
    vID = GetPlayerVehicleID(playerid);
    }
    if(vID == INVALID_VEHICLE_ID)
    {
    SendClientMessage(playerid, 0xFF0000FF, "Error: Nicht nahe oder in einem Fahrzeug.");
    }
    //abschliessen:
    GetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    if(tueren==1)
    {
    tueren = 0;
    }
    else
    {
    tueren = 1;
    }
    SetVehicleParamsEx(vID,motor,licht,alarm,tueren,bonnet,boot,objective);
    SendClientMessage(playerid,blau,"Sie haben die Türen Ihres Fahrzeuges abgeschlossen/aufgeschlossen!");
    }
    if(listitem==3)
    {
    new vID = GetPlayerVehicleID(playerid);
    if(!IsPlayerInAnyVehicle(playerid))return SendClientMessage(playerid, hellgrün, "Du bist in kein Auto!");
    for (new i = 0; i < sizeof(aInfo); i++)
    {
    if(vID == aInfo[i] [id_x])
    {
    if(aInfo[i][besitzer] == sInfo[playerid][db_id])
    {
    new query[256];
    GetVehiclePos(vID, aInfo[i][c_x],aInfo[i][c_y],aInfo[i][c_z]);
    GetVehicleZAngle(vID,aInfo[i][c_r]);
    format(query, sizeof(query), "UPDATE Autos SET x='%f',y='%f',z='%f',r='%f' WHERE id='%i'",aInfo[i] [c_x],aInfo[i] [c_y],aInfo[i] [c_z],aInfo[i] [c_r],aInfo[i] [db_id]);
    mysql_function_query(dbhandle,query,false," "," ");
    SendClientMessage(playerid, hellgrün, "Du hast dein Auto geparkt.");
    return 1;
    }
    break;
    }
    }
    return SendClientMessage(playerid, hellgrün, "Sie sitzen nicht in Ihr Fahrze!");
    }
    } für das sind die sachen fürs Autoparken und so.


    Warum es nun rumbuggt weiß ich leider nicht. Es erstellt sich auch nicht mals eine MySQL.log datei um zu sehen woran es liegen könnte

  • Beitrag von justRevitox ()

    Dieser Beitrag wurde gelöscht, Informationen über den Löschvorgang sind nicht verfügbar.
  • Es erstellt sich auch nicht mals eine MySQL.log


    Die sollte normalerweile da sein.


    mysql_log(LOG_ALL, LOG_TYPE_TEXT); wenn du R35+ verwendest sonst ->
    mysql_log(LOG_ERROR | LOG_WARNING, LOG_TYPE_HTML);


    So müsste immer eine dabei sein.



  • Ob das weiterhelfen kann kp


  • Einen Query falsch geschrieben oder die Query-Größe ist zu klein. Zeig mal bitte OnPlayerCarsLoad.
    Und OnPlayerSave bzw dein public / stock davon.


    //EDIT:


    OnPlayerLoad war ein Fehler ich meine OnPlayerSave bzw sein Public / Stock.

  • SQL
    --Hier fehl ein ' am ende der fraktion
    [20:44:30] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6880',alevel='7',fraktion='2,ra", callback: "(null)", format: "(null)"
    
    
    --ein ' nach der id zu viel
    [20:44:30] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '6' WHERE id='4000'' at line 1
    
    
    --ein ' nach der id zu viel
    [20:49:28] [ERROR] CMySQLQuery::Execute[] - (error #1064) You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '6',spawnchange='0' WHERE id='1'' at line 1


    //edit Änder folgendes ersmal um, falls nochmehr fehler enthalten sind bitte erneut die mysqllog schicken.
    savePlayer(playerid)
    {
    if(sInfo[playerid][eingeloggt]==0)return 1;
    //Speichern level,money
    new query[256];
    format(query,sizeof(query),"UPDATE user SET level='%i',money='%i',alevel='%i',fraktion='%i',rang='%i',spawnchange='%i' WHERE id='%i'",sInfo[playerid][level],GetPlayerMoney(playerid),sInfo[playerid][alevel],sInfo[playerid][fraktion],sInfo[playerid][rang],sInfo[playerid][spawnchange],sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,false,"","");
    return 1;
    }


    public OnPlayerDisconnect(playerid, reason)
    {
    for(new i=0; i<sizeof(aInfo); i++)
    {
    if(aInfo[i][id_x]==0)continue;
    if(aInfo[i][besitzer]!=sInfo[playerid][db_id])continue;
    GetVehiclePos(aInfo[i][id_x],aInfo[i][c_x],aInfo[i][c_y],aInfo[i][c_z]);
    GetVehicleZAngle(aInfo[i][id_x],aInfo[i][c_r]);
    new query[156];
    format(query,sizeof(query),"UPDATE user SET level='%i',money='%i',alevel='%i',fraktion='%i',rang='%i' WHERE id='%i'",sInfo[playerid][level],
    GetPlayerMoney(playerid),sInfo[playerid][alevel],sInfo[playerid][fraktion],sInfo[playerid][rang],sInfo,sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,false,"","");
    DestroyVehicle(aInfo[i][id_x]);
    aInfo[i][id_x]=0;
    break;
    }
    savePlayer(playerid);
    resetPlayer(playerid);
    loadPlayerCars(playerid);
    return 1;
    }

  • do.de - Domain-Offensive - Domains für alle und zu super Preisen
  • Alles was zum Carlod gehört:


    forward OnPlayerCarsLoad(playerid);


    public OnPlayerCarsLoad(playerid)
    {
    new num_fields,num_rows;
    cache_get_data(num_rows,num_fields,dbhandle);
    if(!num_rows)return 1;
    for(new i=0; i<num_rows; i++)
    {
    new id=getFreeCarID();
    aInfo[id][model]=cache_get_field_content_int(i,"model",dbhandle);
    aInfo[id][besitzer]=cache_get_field_content_int(i,"besitzer",dbhandle);
    aInfo[id][c_x]=cache_get_field_content_float(i,"x",dbhandle);
    aInfo[id][c_y]=cache_get_field_content_float(i,"y",dbhandle);
    aInfo[id][c_z]=cache_get_field_content_float(i,"z",dbhandle);
    aInfo[id][c_r]=cache_get_field_content_float(i,"r",dbhandle);
    aInfo[id][db_id]=cache_get_field_content_int(i,"id",dbhandle);
    aInfo[id][id_x]=CreateVehicle(aInfo[id][model],aInfo[id][c_x],aInfo[id][c_y],aInfo[id][c_z],aInfo[id][c_r],-1,-1,-1);
    }
    return 1;
    }


    loadPlayerCars(playerid)
    {
    new query[128];
    format(query,sizeof(query),"SELECT * FROM autos WHERE besitzer='%i'",sInfo[playerid][db_id]);
    mysql_function_query(dbhandle,query,true,"OnPlayerCarsLoad","i",playerid);
    return 1;
    }

  • SQL
    [23:04:44] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:04:44] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:04:44] [DEBUG] CMySQLConnection::Connect - connection was successful[23:04:44] [DEBUG] CMySQLConnection::Connect - connection was successful[23:04:44] [DEBUG] CMySQLConnection::Connect - connection was successful[23:04:44] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:04:44] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:04:44] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:05:13] [DEBUG] mysql_tquery - connection: 1, query: "SELECT id FROM user WHERE username='Blackshadowscript' ", callback: "OnUserCheck", format: "i"[23:05:13] [DEBUG] CMySQLQuery::Execute[OnUserCheck] - starting query execution[23:05:13] [DEBUG] CMySQLQuery::Execute[OnUserCheck] - query was successfully executed within 0.403 milliseconds[23:05:13] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:05:13] [DEBUG] Calling callback "OnUserCheck"..[23:05:13] [DEBUG] cache_get_data - connection: 1[23:05:13] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:05:17] [DEBUG] mysql_escape_string - source: "klom19pom", connection: 1, max_len: 35[23:05:17] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM user WHERE username='Blackshadowscript' AND passwo", callback: "OnPasswordResponse", format: "i"[23:05:17] [DEBUG] CMySQLQuery::Execute[OnPasswordResponse] - starting query execution[23:05:17] [DEBUG] CMySQLQuery::Execute[OnPasswordResponse] - query was successfully executed within 0.385 milliseconds[23:05:17] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:05:17] [DEBUG] Calling callback "OnPasswordResponse"..[23:05:17] [DEBUG] cache_get_data - connection: 1[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "level", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "level", data: "0"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "id", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "id", data: "1"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "money", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "money", data: "6880"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "alevel", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "alevel", data: "7"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "fraktion", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "fraktion", data: "1"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "rang", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "rang", data: "6"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "spawnchange", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "spawnchange", data: "1"[23:05:17] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM autos WHERE besitzer='1'", callback: "OnPlayerCarsLoad", format: "i"[23:05:17] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:05:17] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - starting query execution[23:05:17] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - query was successfully executed within 0.362 milliseconds[23:05:17] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:05:17] [DEBUG] Calling callback "OnPlayerCarsLoad"..[23:05:17] [DEBUG] cache_get_data - connection: 1[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "model", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "model", data: "411"[23:05:17] [DEBUG] cache_get_field_content_int - row: 0, field_name: "besitzer", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "besitzer", data: "1"[23:05:17] [DEBUG] cache_get_field_content_float - row: 0, field_name: "x", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "x", data: "346.643"[23:05:17] [DEBUG] cache_get_field_content_float - row: 0, field_name: "y", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "y", data: "-1520.98"[23:05:17] [DEBUG] cache_get_field_content_float - row: 0, field_name: "z", connection: 1[23:05:17] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "z", data: "32.9203"[23:05:17] [DEBUG] cache_get_field_content_float - row: 0, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "r", data: "322.397"[23:05:18] [DEBUG] cache_get_field_content_int - row: 0, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "id", data: "3"[23:05:18] [DEBUG] cache_get_field_content_int - row: 1, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "model", data: "411"[23:05:18] [DEBUG] cache_get_field_content_int - row: 1, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 1, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "x", data: "2285.24"[23:05:18] [DEBUG] cache_get_field_content_float - row: 1, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "y", data: "2404.82"[23:05:18] [DEBUG] cache_get_field_content_float - row: 1, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "z", data: "10.735"[23:05:18] [DEBUG] cache_get_field_content_float - row: 1, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "r", data: "183.227"[23:05:18] [DEBUG] cache_get_field_content_int - row: 1, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "id", data: "4"[23:05:18] [DEBUG] cache_get_field_content_int - row: 2, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "model", data: "596"[23:05:18] [DEBUG] cache_get_field_content_int - row: 2, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 2, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "x", data: "315.447"[23:05:18] [DEBUG] cache_get_field_content_float - row: 2, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "y", data: "1877.46"[23:05:18] [DEBUG] cache_get_field_content_float - row: 2, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "z", data: "17.6406"[23:05:18] [DEBUG] cache_get_field_content_float - row: 2, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "r", data: "65.1618"[23:05:18] [DEBUG] cache_get_field_content_int - row: 2, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "id", data: "5"[23:05:18] [DEBUG] cache_get_field_content_int - row: 3, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "model", data: "597"[23:05:18] [DEBUG] cache_get_field_content_int - row: 3, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 3, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "x", data: "310.023"[23:05:18] [DEBUG] cache_get_field_content_float - row: 3, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "y", data: "1877.52"[23:05:18] [DEBUG] cache_get_field_content_float - row: 3, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "z", data: "17.6406"[23:05:18] [DEBUG] cache_get_field_content_float - row: 3, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "r", data: "1.96493"[23:05:18] [DEBUG] cache_get_field_content_int - row: 3, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "id", data: "6"[23:05:18] [DEBUG] cache_get_field_content_int - row: 4, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "model", data: "596"[23:05:18] [DEBUG] cache_get_field_content_int - row: 4, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 4, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "x", data: "310.003"[23:05:18] [DEBUG] cache_get_field_content_float - row: 4, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "y", data: "1877.66"[23:05:18] [DEBUG] cache_get_field_content_float - row: 4, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "z", data: "18.2892"[23:05:18] [DEBUG] cache_get_field_content_float - row: 4, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "r", data: "158.66"[23:05:18] [DEBUG] cache_get_field_content_int - row: 4, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "id", data: "7"[23:05:18] [DEBUG] cache_get_field_content_int - row: 5, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "model", data: "411"[23:05:18] [DEBUG] cache_get_field_content_int - row: 5, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 5, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "x", data: "1113.55"[23:05:18] [DEBUG] cache_get_field_content_float - row: 5, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "y", data: "-1706.97"[23:05:18] [DEBUG] cache_get_field_content_float - row: 5, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "z", data: "13.5469"[23:05:18] [DEBUG] cache_get_field_content_float - row: 5, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "r", data: "257.168"[23:05:18] [DEBUG] cache_get_field_content_int - row: 5, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "id", data: "8"[23:05:18] [DEBUG] cache_get_field_content_int - row: 6, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "model", data: "411"[23:05:18] [DEBUG] cache_get_field_content_int - row: 6, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 6, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "x", data: "264.894"[23:05:18] [DEBUG] cache_get_field_content_float - row: 6, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "y", data: "176.445"[23:05:18] [DEBUG] cache_get_field_content_float - row: 6, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "z", data: "1003.02"[23:05:18] [DEBUG] cache_get_field_content_float - row: 6, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "r", data: "94.6413"[23:05:18] [DEBUG] cache_get_field_content_int - row: 6, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "id", data: "9"[23:05:18] [DEBUG] cache_get_field_content_int - row: 7, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "model", data: "400"[23:05:18] [DEBUG] cache_get_field_content_int - row: 7, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 7, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "x", data: "352.108"[23:05:18] [DEBUG] cache_get_field_content_float - row: 7, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "y", data: "-1522.1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 7, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "z", data: "33.1427"[23:05:18] [DEBUG] cache_get_field_content_float - row: 7, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "r", data: "307.562"[23:05:18] [DEBUG] cache_get_field_content_int - row: 7, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "id", data: "10"[23:05:18] [DEBUG] cache_get_field_content_int - row: 8, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "model", data: "411"[23:05:18] [DEBUG] cache_get_field_content_int - row: 8, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 8, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "x", data: "356.038"[23:05:18] [DEBUG] cache_get_field_content_float - row: 8, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "y", data: "-1521.27"[23:05:18] [DEBUG] cache_get_field_content_float - row: 8, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "z", data: "33.0662"[23:05:18] [DEBUG] cache_get_field_content_float - row: 8, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "r", data: "292.951"[23:05:18] [DEBUG] cache_get_field_content_int - row: 8, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "id", data: "11"[23:05:18] [DEBUG] cache_get_field_content_int - row: 9, field_name: "model", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "model", data: "411"[23:05:18] [DEBUG] cache_get_field_content_int - row: 9, field_name: "besitzer", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "besitzer", data: "1"[23:05:18] [DEBUG] cache_get_field_content_float - row: 9, field_name: "x", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "x", data: "214.029"[23:05:18] [DEBUG] cache_get_field_content_float - row: 9, field_name: "y", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "y", data: "160.623"[23:05:18] [DEBUG] cache_get_field_content_float - row: 9, field_name: "z", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "z", data: "1003.02"[23:05:18] [DEBUG] cache_get_field_content_float - row: 9, field_name: "r", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "r", data: "178.458"[23:05:18] [DEBUG] cache_get_field_content_int - row: 9, field_name: "id", connection: 1[23:05:18] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "id", data: "12"[23:05:18] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:06:32] [DEBUG] mysql_tquery - connection: 1, query: "INSERT INTO autos(besitzer,model,x,y,z,r) VALUES('1','411','2743", callback: "carSavedToDB", format: "i"[23:06:32] [DEBUG] CMySQLQuery::Execute[carSavedToDB] - starting query execution[23:06:32] [DEBUG] CMySQLQuery::Execute[carSavedToDB] - query was successfully executed within 71.681 milliseconds[23:06:32] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:06:32] [DEBUG] Calling callback "carSavedToDB"..[23:06:32] [DEBUG] cache_insert_id - connection: 1[23:06:32] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:06:39] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6780',alevel='7',fraktion='2',r", callback: "(null)", format: "(null)"[23:06:39] [DEBUG] CMySQLQuery::Execute[] - starting query execution[23:06:39] [DEBUG] CMySQLQuery::Execute[] - query was successfully executed within 159.418 milliseconds[23:06:39] [DEBUG] CMySQLQuery::Execute[] - no callback specified, skipping result saving[23:09:08] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE Autos SET x='359.739166',y='-1504.330810',z='32.554630',r", callback: " ", format: "(null)"[23:09:08] [DEBUG] CMySQLQuery::Execute[ ] - starting query execution[23:09:08] [DEBUG] CMySQLQuery::Execute[ ] - query was successfully executed within 96.551 milliseconds[23:09:08] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:09:13] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6780',alevel='7',fraktion='2',r", callback: "(null)", format: "(null)"[23:09:13] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6780',alevel='7',fraktion='2',r", callback: "(null)", format: "(null)"[23:09:13] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM autos WHERE besitzer='0'", callback: "OnPlayerCarsLoad", format: "i"[23:09:13] [DEBUG] mysql_close - connection: 1[23:09:13] [DEBUG] CMySQLConnection::Disconnect - connection was closed[23:09:13] [DEBUG] CMySQLConnection::Disconnect - connection was closed[23:09:13] [DEBUG] CMySQLConnection::Disconnect - connection was closed[23:09:13] [DEBUG] CMySQLHandle::~CMySQLHandle - deconstructor called[23:09:25] [DEBUG] mysql_connect - host: "localhost", user: "blackshadow", database: "samp", password: "****", port: 3306, autoreconnect: true, pool_size: 2[23:09:25] [DEBUG] CMySQLHandle::Create - creating new connection..[23:09:25] [DEBUG] CMySQLHandle::CMySQLHandle - constructor called[23:09:25] [DEBUG] CMySQLHandle::Create - connection created (id: 1)[23:09:25] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:09:25] [DEBUG] CMySQLConnection::Connect - connection was successful[23:09:25] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:09:25] [DEBUG] mysql_tquery - connection: 1, query: "SELECT id FROM user WHERE username='Blackshadowscript' ", callback: "OnUserCheck", format: "i"[23:09:25] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:09:25] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:09:25] [DEBUG] CMySQLConnection::Connect - establishing connection to database...[23:09:25] [DEBUG] CMySQLConnection::Connect - connection was successful[23:09:25] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:09:25] [DEBUG] CMySQLQuery::Execute[OnUserCheck] - starting query execution[23:09:25] [DEBUG] CMySQLQuery::Execute[OnUserCheck] - query was successfully executed within 3.582 milliseconds[23:09:25] [DEBUG] CMySQLConnection::Connect - connection was successful[23:09:25] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:09:25] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:09:25] [DEBUG] CMySQLConnection::Connect - connection was successful[23:09:25] [DEBUG] CMySQLConnection::Connect - auto-reconnect has been enabled[23:09:25] [DEBUG] Calling callback "OnUserCheck"..[23:09:25] [DEBUG] cache_get_data - connection: 1[23:09:25] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:09:29] [DEBUG] mysql_escape_string - source: "klom19pom", connection: 1, max_len: 35[23:09:29] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM user WHERE username='Blackshadowscript' AND passwo", callback: "OnPasswordResponse", format: "i"[23:09:29] [DEBUG] CMySQLQuery::Execute[OnPasswordResponse] - starting query execution[23:09:29] [DEBUG] CMySQLQuery::Execute[OnPasswordResponse] - query was successfully executed within 0.409 milliseconds[23:09:29] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:09:29] [DEBUG] Calling callback "OnPasswordResponse"..[23:09:29] [DEBUG] cache_get_data - connection: 1[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "level", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "level", data: "0"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "id", data: "1"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "money", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "money", data: "6780"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "alevel", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "alevel", data: "7"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "fraktion", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "fraktion", data: "2"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "rang", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "rang", data: "6"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "spawnchange", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "spawnchange", data: "0"[23:09:29] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM autos WHERE besitzer='1'", callback: "OnPlayerCarsLoad", format: "i"[23:09:29] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:09:29] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - starting query execution[23:09:29] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - query was successfully executed within 0.353 milliseconds[23:09:29] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:09:29] [DEBUG] Calling callback "OnPlayerCarsLoad"..[23:09:29] [DEBUG] cache_get_data - connection: 1[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 0, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "x", data: "346.643"[23:09:29] [DEBUG] cache_get_field_content_float - row: 0, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "y", data: "-1520.98"[23:09:29] [DEBUG] cache_get_field_content_float - row: 0, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "z", data: "32.9203"[23:09:29] [DEBUG] cache_get_field_content_float - row: 0, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "r", data: "322.397"[23:09:29] [DEBUG] cache_get_field_content_int - row: 0, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '0', field: "id", data: "3"[23:09:29] [DEBUG] cache_get_field_content_int - row: 1, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 1, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 1, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "x", data: "2285.24"[23:09:29] [DEBUG] cache_get_field_content_float - row: 1, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "y", data: "2404.82"[23:09:29] [DEBUG] cache_get_field_content_float - row: 1, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "z", data: "10.735"[23:09:29] [DEBUG] cache_get_field_content_float - row: 1, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "r", data: "183.227"[23:09:29] [DEBUG] cache_get_field_content_int - row: 1, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '1', field: "id", data: "4"[23:09:29] [DEBUG] cache_get_field_content_int - row: 2, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "model", data: "596"[23:09:29] [DEBUG] cache_get_field_content_int - row: 2, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 2, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "x", data: "315.447"[23:09:29] [DEBUG] cache_get_field_content_float - row: 2, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "y", data: "1877.46"[23:09:29] [DEBUG] cache_get_field_content_float - row: 2, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "z", data: "17.6406"[23:09:29] [DEBUG] cache_get_field_content_float - row: 2, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "r", data: "65.1618"[23:09:29] [DEBUG] cache_get_field_content_int - row: 2, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '2', field: "id", data: "5"[23:09:29] [DEBUG] cache_get_field_content_int - row: 3, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "model", data: "597"[23:09:29] [DEBUG] cache_get_field_content_int - row: 3, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 3, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "x", data: "310.023"[23:09:29] [DEBUG] cache_get_field_content_float - row: 3, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "y", data: "1877.52"[23:09:29] [DEBUG] cache_get_field_content_float - row: 3, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "z", data: "17.6406"[23:09:29] [DEBUG] cache_get_field_content_float - row: 3, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "r", data: "1.96493"[23:09:29] [DEBUG] cache_get_field_content_int - row: 3, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '3', field: "id", data: "6"[23:09:29] [DEBUG] cache_get_field_content_int - row: 4, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "model", data: "596"[23:09:29] [DEBUG] cache_get_field_content_int - row: 4, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 4, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "x", data: "310.003"[23:09:29] [DEBUG] cache_get_field_content_float - row: 4, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "y", data: "1877.66"[23:09:29] [DEBUG] cache_get_field_content_float - row: 4, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "z", data: "18.2892"[23:09:29] [DEBUG] cache_get_field_content_float - row: 4, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "r", data: "158.66"[23:09:29] [DEBUG] cache_get_field_content_int - row: 4, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '4', field: "id", data: "7"[23:09:29] [DEBUG] cache_get_field_content_int - row: 5, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 5, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 5, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "x", data: "1113.55"[23:09:29] [DEBUG] cache_get_field_content_float - row: 5, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "y", data: "-1706.97"[23:09:29] [DEBUG] cache_get_field_content_float - row: 5, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "z", data: "13.5469"[23:09:29] [DEBUG] cache_get_field_content_float - row: 5, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "r", data: "257.168"[23:09:29] [DEBUG] cache_get_field_content_int - row: 5, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '5', field: "id", data: "8"[23:09:29] [DEBUG] cache_get_field_content_int - row: 6, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 6, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 6, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "x", data: "264.894"[23:09:29] [DEBUG] cache_get_field_content_float - row: 6, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "y", data: "176.445"[23:09:29] [DEBUG] cache_get_field_content_float - row: 6, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "z", data: "1003.02"[23:09:29] [DEBUG] cache_get_field_content_float - row: 6, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "r", data: "94.6413"[23:09:29] [DEBUG] cache_get_field_content_int - row: 6, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '6', field: "id", data: "9"[23:09:29] [DEBUG] cache_get_field_content_int - row: 7, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "model", data: "400"[23:09:29] [DEBUG] cache_get_field_content_int - row: 7, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 7, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "x", data: "352.108"[23:09:29] [DEBUG] cache_get_field_content_float - row: 7, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "y", data: "-1522.1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 7, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "z", data: "33.1427"[23:09:29] [DEBUG] cache_get_field_content_float - row: 7, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "r", data: "307.562"[23:09:29] [DEBUG] cache_get_field_content_int - row: 7, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '7', field: "id", data: "10"[23:09:29] [DEBUG] cache_get_field_content_int - row: 8, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 8, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 8, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "x", data: "356.038"[23:09:29] [DEBUG] cache_get_field_content_float - row: 8, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "y", data: "-1521.27"[23:09:29] [DEBUG] cache_get_field_content_float - row: 8, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "z", data: "33.0662"[23:09:29] [DEBUG] cache_get_field_content_float - row: 8, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "r", data: "292.951"[23:09:29] [DEBUG] cache_get_field_content_int - row: 8, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '8', field: "id", data: "11"[23:09:29] [DEBUG] cache_get_field_content_int - row: 9, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 9, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 9, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "x", data: "214.029"[23:09:29] [DEBUG] cache_get_field_content_float - row: 9, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "y", data: "160.623"[23:09:29] [DEBUG] cache_get_field_content_float - row: 9, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "z", data: "1003.02"[23:09:29] [DEBUG] cache_get_field_content_float - row: 9, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "r", data: "178.458"[23:09:29] [DEBUG] cache_get_field_content_int - row: 9, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '9', field: "id", data: "12"[23:09:29] [DEBUG] cache_get_field_content_int - row: 10, field_name: "model", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "model", data: "411"[23:09:29] [DEBUG] cache_get_field_content_int - row: 10, field_name: "besitzer", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "besitzer", data: "1"[23:09:29] [DEBUG] cache_get_field_content_float - row: 10, field_name: "x", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "x", data: "359.739"[23:09:29] [DEBUG] cache_get_field_content_float - row: 10, field_name: "y", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "y", data: "-1504.33"[23:09:29] [DEBUG] cache_get_field_content_float - row: 10, field_name: "z", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "z", data: "32.5546"[23:09:29] [DEBUG] cache_get_field_content_float - row: 10, field_name: "r", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "r", data: "116.382"[23:09:29] [DEBUG] cache_get_field_content_int - row: 10, field_name: "id", connection: 1[23:09:29] [DEBUG] CMySQLResult::GetRowDataByName - row: '10', field: "id", data: "13"[23:09:29] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called[23:09:35] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6780',alevel='7',fraktion='2',r", callback: "(null)", format: "(null)"[23:09:35] [DEBUG] mysql_tquery - connection: 1, query: "UPDATE user SET level='0',money='6780',alevel='7',fraktion='2',r", callback: "(null)", format: "(null)"[23:09:35] [DEBUG] mysql_tquery - connection: 1, query: "SELECT * FROM autos WHERE besitzer='0'", callback: "OnPlayerCarsLoad", format: "i"[23:09:35] [DEBUG] CMySQLQuery::Execute[] - starting query execution[23:09:35] [DEBUG] CMySQLQuery::Execute[] - query was successfully executed within 0.336 milliseconds[23:09:35] [DEBUG] CMySQLQuery::Execute[] - no callback specified, skipping result saving[23:09:35] [DEBUG] CMySQLQuery::Execute[] - starting query execution[23:09:35] [DEBUG] CMySQLQuery::Execute[] - query was successfully executed within 0.293 milliseconds[23:09:35] [DEBUG] CMySQLQuery::Execute[] - no callback specified, skipping result saving[23:09:35] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - starting query execution[23:09:35] [DEBUG] CMySQLQuery::Execute[OnPlayerCarsLoad] - query was successfully executed within 0.245 milliseconds[23:09:35] [DEBUG] CMySQLResult::CMySQLResult() - constructor called[23:09:35] [DEBUG] Calling callback "OnPlayerCarsLoad"..[23:09:35] [DEBUG] cache_get_data - connection: 1[23:09:35] [DEBUG] CMySQLResult::~CMySQLResult() - deconstructor called


    anscheind geht nun alles.