Loading data bug again...
#8

I have try'd this, but same problem. Please can someone help me :S really stuck on this..

pawn Код:
new query[1024], pname[24];
    GetPlayerName(playerid, pname, 24);
    format(query, sizeof(query), "SELECT * FROM `PlayerInfo` WHERE `user` = '%s'", pname);
    mysql_query(query);
    mysql_store_result();
    while(mysql_fetch_row_format(query)) {
            new data[9][128];
            new data2[59];
            sscanf(query, "p<|>dddddds[124]dds[124]s[124]s[124]s[124]ddddddddddddddddddddddddddddddddddddds[124]s[124]s[124]dddddddddd",
                data2[0], // Bank
                data2[1], // Hand
                data2[2], // Level
                data2[3], // rpoints
                data2[4], // playertime
                data2[5], // jail
                data[0], // jailreason
                data2[6], // jailtime
                data2[7], // Banned
                data[1], // banreason
                data[2], // whobannedme
                data[3], // whenigotbanned
                data[4], // forumname
                data2[8], // Skin
                data2[9], // ranklvl
                data2[10], // rentprice
                data2[11], // driverlic
                data2[12], // flylic
                data2[13], // namechanges
                data2[14], // boatlic
                data2[15], // weaplic
                data2[16], // jobtime
                data2[17], // jobskill
                data2[18], // pbkills
                data2[19], // pbdeaths
                data2[20], // totalpayt
                data2[21], // housenum
                data2[22], // tracker
                data2[23], // loan
                data2[24], // drugs
                data2[25], // guns
                data2[26], // sguns
                data2[27], // sdrugs
                data2[28], // power
                data2[29], // female
                data2[30], // bail
                data2[31], // premium
                data2[32], // gotphone
                data2[33], // phonenumber
                data2[34], // phonebook
                data2[35], // laptop
                data2[36], // age
                data2[37], // premiumexpire
                data2[38], // playerteam
                data2[39], // radio
                data2[40], // freq1
                data2[41], // freq2
                data2[42], // freq3
                data2[43], // tutorial
                data2[44], // tbanned
                data[5], // city
                data[6], // PTeamName
                data[7], // job
                data2[45], // totalruns
                data2[46], // fpay
                data2[47], // warns
                data2[48], // helper
                data2[49], // curfreq
                data[8], // rankname
                data2[50], // phonechanges
                data2[51], // iPod
                data2[52], // finvite
                data2[53], // fradio
                data2[54], // fstock
                data2[55], // fwarehouse
                data2[56], // fgundealer
                data2[57], // fbarrier
                data2[58]); // fweplic
// ===============================[Integer loads]
            PlayerInfo[playerid][bank] = data2[0];
            PlayerTemp[playerid][sm] = data2[1];
                SetPlayerMoney(playerid, data2[1]);
            PlayerInfo[playerid][playerlvl] = data2[2];
                SetPlayerScore(playerid, data2[2]);
            PlayerInfo[playerid][rpoints] = data2[3];
            PlayerInfo[playerid][playertime] = data2[4];
            PlayerInfo[playerid][jail] = data2[5];
            PlayerInfo[playerid][jailtime] = data2[6];
            PlayerInfo[playerid][banned] = data2[7];
            PlayerInfo[playerid][Skin] = data2[8];
                SetPlayerSkin(playerid, data2[8]);
            PlayerInfo[playerid][ranklvl] = data2[9];
            PlayerInfo[playerid][rentprice] = data2[10];
            PlayerInfo[playerid][driverlic] = data2[11];
            PlayerInfo[playerid][flylic] = data2[12];
            PlayerInfo[playerid][namechanges] = data2[13];
            PlayerInfo[playerid][boatlic] = data2[14];
            PlayerInfo[playerid][weaplic] = data2[15];
            PlayerInfo[playerid][jobtime] = data2[16];
            PlayerInfo[playerid][jobskill] = data2[17];
            PlayerInfo[playerid][pbkills] = data2[18];
            PlayerInfo[playerid][pbdeaths] = data2[19];
            PlayerInfo[playerid][totalpayt] = data2[20];
            PlayerInfo[playerid][housenum] = data2[21];
            PlayerInfo[playerid][tracker] = data2[22];
            PlayerInfo[playerid][loan] = data2[23];
            PlayerInfo[playerid][drugs] = data2[24];
            PlayerInfo[playerid][guns] = data2[25];
            PlayerInfo[playerid][sguns] = data2[26];
            PlayerInfo[playerid][sdrugs] = data2[27];
            PlayerInfo[playerid][power] = data2[28];
            PlayerInfo[playerid][female] = data2[29];
            PlayerInfo[playerid][bail] = data2[30];
            PlayerInfo[playerid][premium] = data2[31];
            PlayerInfo[playerid][gotphone] = data2[32];
            PlayerInfo[playerid][phonenumber] = data2[33];
            PlayerInfo[playerid][phonebook] = data2[34];
            PlayerInfo[playerid][laptop] = data2[35];
            PlayerInfo[playerid][age] = data2[36];
            PlayerInfo[playerid][premiumexpire] = data2[37];
            PlayerInfo[playerid][playerteam] = data2[38];
            PlayerInfo[playerid][radio] = data2[39];
            PlayerInfo[playerid][freq1] = data2[40];
            PlayerInfo[playerid][freq2] = data2[41];
            PlayerInfo[playerid][freq3] = data2[42];
            PlayerInfo[playerid][tutorial] = data2[43];
            PlayerInfo[playerid][tbanned] = data2[44];
            PlayerInfo[playerid][totalruns] = data2[45];
            PlayerInfo[playerid][fpay] = data2[46];
            PlayerInfo[playerid][warns] = data2[47];
            PlayerInfo[playerid][helper] = data2[48];
            PlayerInfo[playerid][curfreq] = data2[49];
            PlayerInfo[playerid][phonechanges] = data2[50];
            PlayerInfo[playerid][iPod] = data2[51];
            PlayerInfo[playerid][finvite] = data2[52];
            PlayerInfo[playerid][fradio] = data2[53];
            PlayerInfo[playerid][fstock] = data2[54];
            PlayerInfo[playerid][fwarehouse] = data2[55];
            PlayerInfo[playerid][fgundealer] = data2[56];
            PlayerInfo[playerid][fbarrier] = data2[57];
            PlayerInfo[playerid][fweplic] = data2[58];
// ========================[Strings]
            myStrcpy(PlayerInfo[playerid][jailreason], data[0]);
            myStrcpy(PlayerInfo[playerid][banreason], data[1]);
            myStrcpy(PlayerInfo[playerid][whobannedme], data[2]);
            myStrcpy(PlayerInfo[playerid][whenigotbanned], data[3]);
            myStrcpy(PlayerInfo[playerid][forumname], data[4]);
            myStrcpy(PlayerInfo[playerid][city], data[5]);
            myStrcpy(PlayerInfo[playerid][PTeamName], data[6]);
            myStrcpy(PlayerInfo[playerid][job], data[7]);
            myStrcpy(PlayerInfo[playerid][rankname], data[8]);
    }
    mysql_free_result();
Reply


Messages In This Thread
Loading data bug again... - by Brandon_More - 15.01.2014, 15:02
Re: Loading data bug again... - by Lorenzo! - 15.01.2014, 15:30
Re: Loading data bug again... - by J4mmyHD - 15.01.2014, 15:41
Re: Loading data bug again... - by Brandon_More - 15.01.2014, 15:42
Re: Loading data bug again... - by Brandon_More - 15.01.2014, 15:52
Re: Loading data bug again... - by Lorenzo! - 15.01.2014, 16:23
Re: Loading data bug again... - by Brandon_More - 15.01.2014, 16:37
Re: Loading data bug again... - by Brandon_More - 15.01.2014, 17:32

Forum Jump:


Users browsing this thread: 2 Guest(s)