SA-MP Forums Archive
Car Not Saving - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Car Not Saving (/showthread.php?tid=456307)



Car Not Saving - Donvalley - 05.08.2013

i've been trying to figure the problem out im using United Roleplay II script and the Player Car Details Should be saved to the SQLlite Accounts.db what is wrong with this script? when you log out and log back in car doesn't exist


pawn Code:
if(PlayerInfo[playerid][pCash] >= CarInfo[i][CarPrice]) // 400k
            {
                if(PlayerInfo[playerid][PlayerVehicleModel1] == 0)
                {
            //      ResetPlayerVehicleEx(playerid, 1);
                    PlayerInfo[playerid][pCash] -= CarInfo[i][CarPrice];
                    PlayerInfo[playerid][PlayerVehiclePosX1] = CarInfo[i][CarSpawnX];
                    PlayerInfo[playerid][PlayerVehiclePosY1] = CarInfo[i][CarSpawnY];
                    PlayerInfo[playerid][PlayerVehiclePosZ1] = CarInfo[i][CarSpawnZ];
                    PlayerInfo[playerid][PlayerVehicleFacing1] = CarInfo[i][CarSpawnF];
                    PlayerInfo[playerid][PlayerVehicleModel1] = CarInfo[i][CarModel];
                    PlayerInfo[playerid][pPlayerVehicle1Color] = CarInfo[i][CarColor];
                    PlayerInfo[playerid][pPlayerVehicle1Color2] = CarInfo[i][CarColor2];
                    OnPlayerSave(playerid);
                    RemovePlayerFromVehicle(playerid);
                    CreatePlayerVehicle(playerid, 1);
                    PutPlayerInVehicle(playerid,PlayerVehicleID1[playerid],0);
                    TempCarID[playerid] = 0;
                    format(string,sizeof(string),"  Congratulations on your purchase of %s, Buy a lock from any Locks Store.",vehName[PlayerInfo[playerid][PlayerVehicleModel1]-400]);
                    SendClientMessage(playerid,COLOR_YELLOW,string);
                    return 1;
                }



Re: Car Not Saving - Donvalley - 05.08.2013

bump


Re: Car Not Saving - Donvalley - 06.08.2013

bump


Re: Car Not Saving - Chu - 06.08.2013

I also use the GM United.

I use this FS, but not saved paintjobs
https://sampforum.blast.hk/showthread.php?tid=109669

sorry my bad english


Re: Car Not Saving - Donvalley - 06.08.2013

its something with my onplayersave i think its not saving the vehicle data:

Onplayersave:

pawn Code:
stock OnPlayerSave(playerid)
{
    if (IsPlayerConnected(playerid) && !IsPlayerNPC(playerid))
    {
        if (gPlayerLogged[playerid] != 0 && gPlayerSpawned[playerid] == 1)
        {
            new playername[24];
            GetPlayerName(playerid, playername, sizeof(playername));
            if (SQL_AccountExists(playername))
            {
                if(gmx == 0)
                {
                    GetPlayerHealth(playerid, PlayerInfo[playerid][pHealth]);
                    GetPlayerArmour(playerid, PlayerInfo[playerid][pArmor]);
                }
                PlayerInfo[playerid][pInt] = GetPlayerInterior(playerid);
                PlayerInfo[playerid][pVirtualWorld] = GetPlayerVirtualWorld(playerid);

                GetPlayerPos(playerid, PlayerInfo[playerid][pSPos_x], PlayerInfo[playerid][pSPos_y], PlayerInfo[playerid][pSPos_z]);
                GetPlayerFacingAngle(playerid, PlayerInfo[playerid][pSPos_r]);

                new index = SQL_PrepareUpdate(playername);
                if (index != -1)
                {
                    SQL_UpdateString(index, "Username", playername);
                    SQL_UpdateString(index, "Password", PlayerInfo[playerid][pKey]);
                    SQL_UpdateInt(index, "Level",PlayerInfo[playerid][pLevel]);
                    SQL_UpdateInt(index, "AdminLevel",PlayerInfo[playerid][pAdmin]);
                    SQL_UpdateInt(index, "Band",PlayerInfo[playerid][pBand]);
                    SQL_UpdateInt(index, "PermBand",PlayerInfo[playerid][pPermBand]);
                    SQL_UpdateInt(index, "Warnings",PlayerInfo[playerid][pWarns]);
                    SQL_UpdateInt(index, "TruckerCooldown",PlayerInfo[playerid][pTruckerCooldown]);
                    SQL_UpdateInt(index, "Disabled",PlayerInfo[playerid][pDisabled]);
                    SQL_UpdateInt(index, "DonateRank",PlayerInfo[playerid][pDonateRank]);
                    SQL_UpdateInt(index, "FactionBanned",PlayerInfo[playerid][pFactionBanned]);
                    SQL_UpdateInt(index, "LaserOwner",PlayerInfo[playerid][pLaserOwner]);
                    SQL_UpdateInt(index, "FCard",PlayerInfo[playerid][pFcard]);
                    SQL_UpdateInt(index, "Inbuilding",PlayerInfo[playerid][Inbuilding]);
                    SQL_UpdateInt(index, "BanAppealer",PlayerInfo[playerid][pBanAppealer]);
                    SQL_UpdateInt(index, "GangMod",PlayerInfo[playerid][pGangMod]);
                    SQL_UpdateInt(index, "buildingInterior", PlayerInfo[playerid][buildingInterior]);
                    SQL_UpdateInt(index, "buildingExterior", PlayerInfo[playerid][buildingExterior]);
                    SQL_UpdateFloat(index, "cExtX", PlayerInfo[playerid][cExtX]);
                    SQL_UpdateFloat(index, "cExtY", PlayerInfo[playerid][cExtY]);
                    SQL_UpdateFloat(index, "cExtZ", PlayerInfo[playerid][cExtZ]);
                    SQL_UpdateFloat(index, "cIntX", PlayerInfo[playerid][cIntX]);
                    SQL_UpdateFloat(index, "cIntY", PlayerInfo[playerid][cIntY]);
                    SQL_UpdateFloat(index, "cIntZ", PlayerInfo[playerid][cIntZ]);
                    SQL_UpdateInt(index, "FactionMod",PlayerInfo[playerid][pFactionMod]);
                    SQL_UpdateInt(index, "UpgradePoints",PlayerInfo[playerid][gPupgrade]);
                    SQL_UpdateInt(index, "Inmotel",PlayerInfo[playerid][Inmotel]);
                    SQL_UpdateInt(index, "motelInterior", PlayerInfo[playerid][motelInterior]);
                    SQL_UpdateInt(index, "motelExterior", PlayerInfo[playerid][motelExterior]);
                    SQL_UpdateFloat(index, "mExtX", PlayerInfo[playerid][mExtX]);
                    SQL_UpdateFloat(index, "mExtY", PlayerInfo[playerid][mExtY]);
                    SQL_UpdateFloat(index, "mExtZ", PlayerInfo[playerid][mExtZ]);
                    SQL_UpdateFloat(index, "mIntX", PlayerInfo[playerid][mIntX]);
                    SQL_UpdateFloat(index, "mIntY", PlayerInfo[playerid][mIntY]);
                    SQL_UpdateFloat(index, "mIntZ", PlayerInfo[playerid][mIntZ]);
                    SQL_UpdateInt(index, "ConnectedTime",PlayerInfo[playerid][pConnectTime]);
                    SQL_UpdateFloat(index, "dExtX", PlayerInfo[playerid][dExtX]);
                    SQL_UpdateFloat(index, "dExtY", PlayerInfo[playerid][dExtY]);
                    SQL_UpdateFloat(index, "dExtZ", PlayerInfo[playerid][dExtZ]);
                    SQL_UpdateFloat(index, "dAngle", PlayerInfo[playerid][dAngle]);
                    SQL_UpdateInt(index, "Registered",PlayerInfo[playerid][pReg]);
                    SQL_UpdateInt(index, "Sex",PlayerInfo[playerid][pSex]);
                    SQL_UpdateInt(index, "Developer",PlayerInfo[playerid][pDeveloper]);
                    SQL_UpdateInt(index, "Mapper",PlayerInfo[playerid][pMapper]);
                    SQL_UpdateInt(index, "Division",PlayerInfo[playerid][pDivision]);
                    SQL_UpdateInt(index, "Tester",PlayerInfo[playerid][pTester]);
                    SQL_UpdateInt(index, "Age",PlayerInfo[playerid][pAge]);
                    SQL_UpdateInt(index, "RPBoost",PlayerInfo[playerid][pRPBoost]);
                    SQL_UpdateInt(index, "Origin",PlayerInfo[playerid][pOrigin]);
                    SQL_UpdateInt(index, "ATMcard",PlayerInfo[playerid][pATMcard]);
                    SQL_UpdateInt(index, "GreenCard",PlayerInfo[playerid][pGreenCard]);
                    SQL_UpdateInt(index, "SocialNumber",PlayerInfo[playerid][pSocialNumber]);
                    SQL_UpdateInt(index, "Muted",PlayerInfo[playerid][pMuted]);
                    SQL_UpdateInt(index, "Respect",PlayerInfo[playerid][pExp]);
                    SQL_UpdateInt(index, "Money",PlayerInfo[playerid][pCash]);
                    SQL_UpdateInt(index, "ATMExterior", PlayerInfo[playerid][ATMExterior]);
                    SQL_UpdateInt(index, "MAPBExterior", PlayerInfo[playerid][MAPBExterior]);
                    SQL_UpdateInt(index, "GSTATIONExterior", PlayerInfo[playerid][GSTATIONExterior]);
                    SQL_UpdateInt(index, "HSSignExterior", PlayerInfo[playerid][HSSignExterior]);
                    SQL_UpdateInt(index, "CasinoWinnings",PlayerInfo[playerid][pCasinoWinnings]);
                    SQL_UpdateInt(index, "Bank",PlayerInfo[playerid][pAccount]);
                    SQL_UpdateInt(index, "Crimes",PlayerInfo[playerid][pCrimes]);
                    SQL_UpdateString(index, "Accent",Accent[playerid]);
                    SQL_UpdateInt(index, "ATMID",PlayerInfo[playerid][ATMID]);
                    SQL_UpdateInt(index, "Kills",PlayerInfo[playerid][pKills]);
                    SQL_UpdateInt(index, "Deaths",PlayerInfo[playerid][pDeaths]);
                    SQL_UpdateInt(index, "TrashSkill",PlayerInfo[playerid][pTrashSkill]); // Trashman
                    SQL_UpdateInt(index, "CHits",PlayerInfo[playerid][pCHits]);
                    SQL_UpdateInt(index, "BriefCase",PlayerInfo[playerid][pBriefCase]);
                    SQL_UpdateInt(index, "BCash",PlayerInfo[playerid][pBCash]);
                    SQL_UpdateInt(index, "BCrack",PlayerInfo[playerid][pBCrack]);
                    SQL_UpdateInt(index, "BPot",PlayerInfo[playerid][pBPot]);
                    SQL_UpdateInt(index, "FHits",PlayerInfo[playerid][pFHits]);
                    SQL_UpdateInt(index, "Arrested",PlayerInfo[playerid][pArrested]);
                    SQL_Update(index);

                    index = SQL_PrepareUpdate(playername);
                    SQL_UpdateInt(index, "PlayerVehicleModel1",PlayerInfo[playerid][PlayerVehicleModel1]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing1",PlayerInfo[playerid][PlayerVehicleFacing1]);
                    SQL_UpdateInt(index, "PlayerVehicle1Color",PlayerInfo[playerid][pPlayerVehicle1Color]);
                    SQL_UpdateInt(index, "PlayerVehicle1Color2",PlayerInfo[playerid][pPlayerVehicle1Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX1",PlayerInfo[playerid][PlayerVehiclePosX1]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY1",PlayerInfo[playerid][PlayerVehiclePosY1]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ1",PlayerInfo[playerid][PlayerVehiclePosZ1]);
                    SQL_UpdateInt(index, "PlayerVehicle1PaintJob",PlayerInfo[playerid][PlayerVehicle1PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle1Nos",PlayerInfo[playerid][PlayerVehicle1Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot0",PlayerInfo[playerid][PlayerVehicle1ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot1",PlayerInfo[playerid][PlayerVehicle1ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot2",PlayerInfo[playerid][PlayerVehicle1ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot3",PlayerInfo[playerid][PlayerVehicle1ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot4",PlayerInfo[playerid][PlayerVehicle1ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot5",PlayerInfo[playerid][PlayerVehicle1ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot6",PlayerInfo[playerid][PlayerVehicle1ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot7",PlayerInfo[playerid][PlayerVehicle1ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot8",PlayerInfo[playerid][PlayerVehicle1ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot9",PlayerInfo[playerid][PlayerVehicle1ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot10",PlayerInfo[playerid][PlayerVehicle1ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot11",PlayerInfo[playerid][PlayerVehicle1ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot12",PlayerInfo[playerid][PlayerVehicle1ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot13",PlayerInfo[playerid][PlayerVehicle1ModSlot13]);
                    SQL_UpdateInt(index, "VehLock1",PlayerInfo[playerid][pVehLock1]);
                    SQL_UpdateInt(index, "VehLocked1",PlayerInfo[playerid][pVehLocked1]);
                    SQL_UpdateInt(index, "PlayerVehicle1Interior",PlayerInfo[playerid][PlayerVehicle1Interior]);
                    SQL_UpdateInt(index, "PlayerVehicle1VirWorld",PlayerInfo[playerid][PlayerVehicle1VirWorld]);
                    SQL_UpdateInt(index, "PlayerVehicleModel2",PlayerInfo[playerid][PlayerVehicleModel2]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing2",PlayerInfo[playerid][PlayerVehicleFacing2]);
                    SQL_UpdateInt(index, "PlayerVehicle2Color",PlayerInfo[playerid][pPlayerVehicle2Color]);
                    SQL_UpdateInt(index, "PlayerVehicle2Color2",PlayerInfo[playerid][pPlayerVehicle2Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX2",PlayerInfo[playerid][PlayerVehiclePosX2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY2",PlayerInfo[playerid][PlayerVehiclePosY2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ2",PlayerInfo[playerid][PlayerVehiclePosZ2]);
                    SQL_UpdateInt(index, "PlayerVehicle2PaintJob",PlayerInfo[playerid][PlayerVehicle2PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle2Nos",PlayerInfo[playerid][PlayerVehicle2Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot0",PlayerInfo[playerid][PlayerVehicle2ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot1",PlayerInfo[playerid][PlayerVehicle2ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot2",PlayerInfo[playerid][PlayerVehicle2ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot3",PlayerInfo[playerid][PlayerVehicle2ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot4",PlayerInfo[playerid][PlayerVehicle2ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot5",PlayerInfo[playerid][PlayerVehicle2ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot6",PlayerInfo[playerid][PlayerVehicle2ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot7",PlayerInfo[playerid][PlayerVehicle2ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot8",PlayerInfo[playerid][PlayerVehicle2ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot9",PlayerInfo[playerid][PlayerVehicle2ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot10",PlayerInfo[playerid][PlayerVehicle2ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot11",PlayerInfo[playerid][PlayerVehicle2ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot12",PlayerInfo[playerid][PlayerVehicle2ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle2ModSlot13",PlayerInfo[playerid][PlayerVehicle2ModSlot13]);
                    SQL_UpdateInt(index, "VehLock2",PlayerInfo[playerid][pVehLock2]);
                    SQL_UpdateInt(index, "VehLocked2",PlayerInfo[playerid][pVehLocked2]);
                    SQL_UpdateInt(index, "PlayerVehicle2Interior",PlayerInfo[playerid][PlayerVehicle2Interior]);
                    SQL_UpdateInt(index, "PlayerVehicle2VirWorld",PlayerInfo[playerid][PlayerVehicle2VirWorld]);
                    SQL_UpdateInt(index, "PlayerVehicleModel3",PlayerInfo[playerid][PlayerVehicleModel3]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing3",PlayerInfo[playerid][PlayerVehicleFacing3]);
                    SQL_UpdateInt(index, "PlayerVehicle3Color",PlayerInfo[playerid][pPlayerVehicle3Color]);
                    SQL_UpdateInt(index, "PlayerVehicle3Color2",PlayerInfo[playerid][pPlayerVehicle3Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX3",PlayerInfo[playerid][PlayerVehiclePosX3]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY3",PlayerInfo[playerid][PlayerVehiclePosY3]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ3",PlayerInfo[playerid][PlayerVehiclePosZ3]);
                    SQL_UpdateInt(index, "PlayerVehicle3PaintJob",PlayerInfo[playerid][PlayerVehicle3PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle3Nos",PlayerInfo[playerid][PlayerVehicle3Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot0",PlayerInfo[playerid][PlayerVehicle3ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot1",PlayerInfo[playerid][PlayerVehicle3ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot2",PlayerInfo[playerid][PlayerVehicle3ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot3",PlayerInfo[playerid][PlayerVehicle3ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot4",PlayerInfo[playerid][PlayerVehicle3ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot5",PlayerInfo[playerid][PlayerVehicle3ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot6",PlayerInfo[playerid][PlayerVehicle3ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot7",PlayerInfo[playerid][PlayerVehicle3ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot8",PlayerInfo[playerid][PlayerVehicle3ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot9",PlayerInfo[playerid][PlayerVehicle3ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot10",PlayerInfo[playerid][PlayerVehicle3ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot11",PlayerInfo[playerid][PlayerVehicle3ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot12",PlayerInfo[playerid][PlayerVehicle3ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle3ModSlot13",PlayerInfo[playerid][PlayerVehicle3ModSlot13]);
                    SQL_UpdateInt(index, "VehLock3",PlayerInfo[playerid][pVehLock3]);
                    SQL_UpdateInt(index, "VehLocked3",PlayerInfo[playerid][pVehLocked3]);
                    SQL_UpdateInt(index, "PlayerVehicle3Interior",PlayerInfo[playerid][PlayerVehicle3Interior]);
                    SQL_UpdateInt(index, "PlayerVehicle3VirWorld",PlayerInfo[playerid][PlayerVehicle3VirWorld]);
                    SQL_UpdateInt(index, "PlayerVehicleModel4",PlayerInfo[playerid][PlayerVehicleModel4]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing4",PlayerInfo[playerid][PlayerVehicleFacing4]);
                    SQL_UpdateInt(index, "PlayerVehicle4Color",PlayerInfo[playerid][pPlayerVehicle4Color]);
                    SQL_UpdateInt(index, "PlayerVehicle4Color2",PlayerInfo[playerid][pPlayerVehicle4Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX4",PlayerInfo[playerid][PlayerVehiclePosX4]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY4",PlayerInfo[playerid][PlayerVehiclePosY4]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ4",PlayerInfo[playerid][PlayerVehiclePosZ4]);
                    SQL_UpdateInt(index, "PlayerVehicle4PaintJob",PlayerInfo[playerid][PlayerVehicle4PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle4Nos",PlayerInfo[playerid][PlayerVehicle4Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot0",PlayerInfo[playerid][PlayerVehicle4ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot1",PlayerInfo[playerid][PlayerVehicle4ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot2",PlayerInfo[playerid][PlayerVehicle4ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot3",PlayerInfo[playerid][PlayerVehicle4ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot4",PlayerInfo[playerid][PlayerVehicle4ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot5",PlayerInfo[playerid][PlayerVehicle4ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot6",PlayerInfo[playerid][PlayerVehicle4ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot7",PlayerInfo[playerid][PlayerVehicle4ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot8",PlayerInfo[playerid][PlayerVehicle4ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot9",PlayerInfo[playerid][PlayerVehicle4ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot10",PlayerInfo[playerid][PlayerVehicle4ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot11",PlayerInfo[playerid][PlayerVehicle4ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot12",PlayerInfo[playerid][PlayerVehicle4ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle4ModSlot13",PlayerInfo[playerid][PlayerVehicle4ModSlot13]);
                    SQL_UpdateInt(index, "VehLock4",PlayerInfo[playerid][pVehLock4]);
                    SQL_UpdateInt(index, "VehLocked4",PlayerInfo[playerid][pVehLocked4]);
                    SQL_UpdateInt(index, "PlayerVehicle4Interior",PlayerInfo[playerid][PlayerVehicle4Interior]);
                    SQL_UpdateInt(index, "PlayerVehicle4VirWorld",PlayerInfo[playerid][PlayerVehicle4VirWorld]);
                    SQL_UpdateInt(index, "PlayerVehicleModel5",PlayerInfo[playerid][PlayerVehicleModel5]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing5",PlayerInfo[playerid][PlayerVehicleFacing5]);
                    SQL_UpdateInt(index, "PlayerVehicle5Color",PlayerInfo[playerid][pPlayerVehicle5Color]);
                    SQL_UpdateInt(index, "PlayerVehicle5Color2",PlayerInfo[playerid][pPlayerVehicle5Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX5",PlayerInfo[playerid][PlayerVehiclePosX5]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY5",PlayerInfo[playerid][PlayerVehiclePosY5]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ5",PlayerInfo[playerid][PlayerVehiclePosZ5]);
                    SQL_UpdateInt(index, "PlayerVehicle5PaintJob",PlayerInfo[playerid][PlayerVehicle5PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle5Nos",PlayerInfo[playerid][PlayerVehicle5Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot0",PlayerInfo[playerid][PlayerVehicle5ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot1",PlayerInfo[playerid][PlayerVehicle5ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot2",PlayerInfo[playerid][PlayerVehicle5ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot3",PlayerInfo[playerid][PlayerVehicle5ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot4",PlayerInfo[playerid][PlayerVehicle5ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot5",PlayerInfo[playerid][PlayerVehicle5ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot6",PlayerInfo[playerid][PlayerVehicle5ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot7",PlayerInfo[playerid][PlayerVehicle5ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot8",PlayerInfo[playerid][PlayerVehicle5ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot9",PlayerInfo[playerid][PlayerVehicle5ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot10",PlayerInfo[playerid][PlayerVehicle5ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot11",PlayerInfo[playerid][PlayerVehicle5ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot12",PlayerInfo[playerid][PlayerVehicle5ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle5ModSlot13",PlayerInfo[playerid][PlayerVehicle5ModSlot13]);
                    SQL_UpdateInt(index, "VehLock5",PlayerInfo[playerid][pVehLock5]);
                    SQL_UpdateInt(index, "VehLocked5",PlayerInfo[playerid][pVehLocked5]);
                    SQL_UpdateInt(index, "PlayerVehicle5Interior",PlayerInfo[playerid][PlayerVehicle5Interior]);
                    SQL_UpdateInt(index, "PlayerVehicle5VirWorld",PlayerInfo[playerid][PlayerVehicle5VirWorld]);
                    SQL_UpdateInt(index, "CarTime",PlayerInfo[playerid][pCarTime]);
                    SQL_UpdateInt(index, "Phonebook",PlayerInfo[playerid][pPhoneBook]);
                    SQL_UpdateInt(index, "HouseTicket",PlayerInfo[playerid][pHouseTicket]);
                    SQL_UpdateInt(index, "BusinessTicket",PlayerInfo[playerid][pBusinessTicket]);
                    SQL_UpdateInt(index, "VehicleTicket",PlayerInfo[playerid][pVehicleTicket]);
                    SQL_UpdateInt(index, "GateTicket",PlayerInfo[playerid][pGateTicket]);
                    SQL_UpdateInt(index, "GarageTicket",PlayerInfo[playerid][pGarageTicket]);
                    SQL_UpdateInt(index, "BoomBox",PlayerInfo[playerid][pBoomBox]);
                    SQL_UpdateInt(index, "LottoNr",PlayerInfo[playerid][pLottoNr]);
                    SQL_UpdateInt(index, "Fishes",PlayerInfo[playerid][pFishes]);
                    SQL_UpdateInt(index, "BiggestFish",PlayerInfo[playerid][pBiggestFish]);
                    SQL_UpdateInt(index, "Job",PlayerInfo[playerid][pJob]);
                    SQL_UpdateInt(index, "Job2",PlayerInfo[playerid][pJob2]);
                    SQL_UpdateInt(index, "Paycheck",PlayerInfo[playerid][pPayCheck]);
                    SQL_UpdateInt(index, "HeadValue",PlayerInfo[playerid][pHeadValue]);
                    SQL_UpdateInt(index, "BHHeadValue",PlayerInfo[playerid][pBHHeadValue]);
                    SQL_UpdateInt(index, "Jailed",PlayerInfo[playerid][pJailed]);
                    SQL_Update(index);

                    index = SQL_PrepareUpdate(playername);
                    SQL_UpdateString(index, "JailedReason",PlayerInfo[playerid][pJailedReason]);
                    SQL_UpdateInt(index, "JailTime",PlayerInfo[playerid][pJailTime]);
                    SQL_UpdateInt(index, "Gun parts",PlayerInfo[playerid][pMats]);
                    SQL_UpdateInt(index, "Pot",PlayerInfo[playerid][pPot]);
                    SQL_UpdateInt(index, "Bong",PlayerInfo[playerid][pBong]);
                    SQL_UpdateInt(index, "Pipe",PlayerInfo[playerid][pPipe]);
                    SQL_UpdateInt(index, "Paper",PlayerInfo[playerid][pPaper]);
                    SQL_UpdateInt(index, "Crack",PlayerInfo[playerid][pCrack]);
                    SQL_UpdateInt(index, "Leader",PlayerInfo[playerid][pLeader]);
                    SQL_UpdateInt(index, "Member",PlayerInfo[playerid][pMember]);
                    SQL_UpdateInt(index, "FMember",PlayerInfo[playerid][pFMember]);
                    SQL_UpdateInt(index, "Rank",PlayerInfo[playerid][pRank]);
                    SQL_UpdateInt(index, "DetSkill",PlayerInfo[playerid][pDetSkill]);
                    SQL_UpdateInt(index, "SexSkill",PlayerInfo[playerid][pSexSkill]);
                    SQL_UpdateInt(index, "BoxSkill",PlayerInfo[playerid][pBoxSkill]);
                    SQL_UpdateInt(index, "LawSkill",PlayerInfo[playerid][pLawSkill]);
                    SQL_UpdateInt(index, "MechSkill",PlayerInfo[playerid][pMechSkill]);
                    SQL_UpdateInt(index, "JackSkill",PlayerInfo[playerid][pJackSkill]);
                    SQL_UpdateInt(index, "CarSkill",PlayerInfo[playerid][pCarSkill]);
                    SQL_UpdateInt(index, "NewsSkill",PlayerInfo[playerid][pNewsSkill]);
                    SQL_UpdateInt(index, "DrugsSkill",PlayerInfo[playerid][pDrugsSkill]);
                    SQL_UpdateInt(index, "ArmsSkill",PlayerInfo[playerid][pArmsSkill]);
                    SQL_UpdateInt(index, "House",PlayerInfo[playerid][pPhousekey]);
                    SQL_UpdateInt(index, "InGarage",PlayerInfo[playerid][InGarage]);
                    SQL_UpdateInt(index, "HouseExterior", PlayerInfo[playerid][HouseInterior]);
                    SQL_UpdateInt(index, "HouseInterior", PlayerInfo[playerid][HouseInterior]);
                    SQL_UpdateFloat(index, "hExtX", PlayerInfo[playerid][hExtX]);
                    SQL_UpdateFloat(index, "hExtY", PlayerInfo[playerid][hExtY]);
                    SQL_UpdateFloat(index, "hExtZ", PlayerInfo[playerid][hExtZ]);
                    SQL_UpdateFloat(index, "hIntX", PlayerInfo[playerid][hIntX]);
                    SQL_UpdateFloat(index, "hIntY", PlayerInfo[playerid][hIntY]);
                    SQL_UpdateFloat(index, "hIntZ", PlayerInfo[playerid][hIntZ]);
                    SQL_UpdateInt(index, "SmugglerSkill",PlayerInfo[playerid][pSmugglerSkill]);
                    SQL_UpdateInt(index, "FishSkill",PlayerInfo[playerid][pFishSkill]);
                    SQL_UpdateInt(index, "FightingStyle",PlayerInfo[playerid][pFightingStyle]);
                    SQL_UpdateFloat(index, "pHealth",PlayerInfo[playerid][pHealth]);
                    SQL_UpdateFloat(index, "pArmor",PlayerInfo[playerid][pArmor]);
                    SQL_UpdateInt(index, "pSHealth",PlayerInfo[playerid][pSHealth]);
                    SQL_UpdateInt(index, "Int",PlayerInfo[playerid][pInt]);
                    SQL_UpdateInt(index, "Local",PlayerInfo[playerid][pLocal]);
                    SQL_UpdateInt(index, "VirtualWorld",PlayerInfo[playerid][pVirtualWorld]);
                    SQL_UpdateInt(index, "Model",PlayerInfo[playerid][pModel]);
                    SQL_UpdateInt(index, "Tikis",PlayerInfo[playerid][pTikis]);
                    SQL_UpdateInt(index, "Clothes",PlayerInfo[playerid][pClothes]);
                    SQL_UpdateInt(index, "PhoneNr",PlayerInfo[playerid][pPnumber]);
                    SQL_UpdateInt(index, "Apartment",PlayerInfo[playerid][pPaptkey]);
                    SQL_UpdateInt(index, "CarLic",PlayerInfo[playerid][pCarLic]);
                    SQL_UpdateInt(index, "FlyLic",PlayerInfo[playerid][pFlyLic]);
                    SQL_UpdateInt(index, "BoatLic",PlayerInfo[playerid][pBoatLic]);
                    SQL_UpdateInt(index, "FishLic",PlayerInfo[playerid][pFishLic]);
                    SQL_UpdateInt(index, "GunLic",PlayerInfo[playerid][pGunLic]);
                    SQL_UpdateInt(index, "Gun0",PlayerInfo[playerid][pGun0]);
                    SQL_UpdateInt(index, "Gun1",PlayerInfo[playerid][pGun1]);
                    SQL_UpdateInt(index, "Gun2",PlayerInfo[playerid][pGun2]);
                    SQL_UpdateInt(index, "Gun3",PlayerInfo[playerid][pGun3]);
                    SQL_UpdateInt(index, "InBusiness",PlayerInfo[playerid][InBusiness]);
                    SQL_UpdateInt(index, "BusinessInterior", PlayerInfo[playerid][BusinessInterior]);
                    SQL_UpdateInt(index, "BusinessExterior", PlayerInfo[playerid][BusinessExterior]);
                    SQL_UpdateInt(index, "Bizz",PlayerInfo[playerid][pPbiskey]);
                    SQL_UpdateInt(index, "Garage",PlayerInfo[playerid][pGarageKey]);
                    SQL_UpdateInt(index, "GarageII",PlayerInfo[playerid][pGarageKey2]);
                    SQL_UpdateInt(index, "House",PlayerInfo[playerid][pHouseKey]);
                    SQL_UpdateInt(index, "HouseII",PlayerInfo[playerid][pHouseKey2]);
                    SQL_UpdateInt(index, "HouseIII",PlayerInfo[playerid][pHouseKey3]);
                    SQL_UpdateInt(index, "HouseIIII",PlayerInfo[playerid][pHouseKey4]);
                    SQL_UpdateInt(index, "GateKey",PlayerInfo[playerid][pGateKey]);
                    SQL_UpdateInt(index, "GateKeyIA",PlayerInfo[playerid][pGateKey2]);
                    SQL_UpdateInt(index, "GateKeyIB",PlayerInfo[playerid][pGateKey3]);
                    SQL_UpdateInt(index, "GateKeyIC",PlayerInfo[playerid][pGateKey4]);
                    SQL_UpdateInt(index, "GateKeyID",PlayerInfo[playerid][pGateKey5]);
                    SQL_UpdateInt(index, "GateKeyIE",PlayerInfo[playerid][pGateKey6]);
                    SQL_UpdateInt(index, "GateKeyIF",PlayerInfo[playerid][pGateKey7]);
                    SQL_UpdateInt(index, "GateKeyIG",PlayerInfo[playerid][pGateKey8]);
                    SQL_UpdateInt(index, "GateKeyIH",PlayerInfo[playerid][pGateKey9]);
                    SQL_UpdateInt(index, "GateKeyII",PlayerInfo[playerid][pGateKey10]);
                    SQL_UpdateFloat(index, "bExtX", PlayerInfo[playerid][bExtX]);
                    SQL_UpdateFloat(index, "bExtY", PlayerInfo[playerid][bExtY]);
                    SQL_UpdateFloat(index, "bExtZ", PlayerInfo[playerid][bExtZ]);
                    SQL_UpdateFloat(index, "bIntX", PlayerInfo[playerid][bIntX]);
                    SQL_UpdateFloat(index, "bIntY", PlayerInfo[playerid][bIntY]);
                    SQL_UpdateFloat(index, "bIntZ", PlayerInfo[playerid][bIntZ]);
                    SQL_UpdateInt(index, "Gun4",PlayerInfo[playerid][pGun4]);
                    SQL_UpdateInt(index, "Gun5",PlayerInfo[playerid][pGun5]);
                    SQL_UpdateInt(index, "Gun6",PlayerInfo[playerid][pGun6]);
                    SQL_UpdateInt(index, "Gun7",PlayerInfo[playerid][pGun7]);
                    SQL_UpdateInt(index, "Gun8",PlayerInfo[playerid][pGun8]);
                    SQL_UpdateInt(index, "Gun9",PlayerInfo[playerid][pGun9]);
                    SQL_UpdateInt(index, "Gun10",PlayerInfo[playerid][pGun10]);
                    SQL_UpdateInt(index, "Gun11",PlayerInfo[playerid][pGun11]);
                    SQL_UpdateInt(index, "Gun12",PlayerInfo[playerid][pGun12]);
                    SQL_UpdateInt(index, "CarTime",PlayerInfo[playerid][pCarTime]);
                    SQL_UpdateInt(index, "DrugsTime",PlayerInfo[playerid][pDrugsTime]);
                    SQL_UpdateInt(index, "LawyerTime",PlayerInfo[playerid][pLawyerTime]);
                    SQL_UpdateInt(index, "LawyerFreeTime",PlayerInfo[playerid][pLawyerFreeTime]);
                    SQL_UpdateInt(index, "MechTime",PlayerInfo[playerid][pMechTime]);
                    SQL_UpdateInt(index, "SexTime",PlayerInfo[playerid][pSexTime]);
                    SQL_UpdateInt(index, "PayDay",PlayerInfo[playerid][pPayDay]);
                    SQL_UpdateInt(index, "PayDayHad",PlayerInfo[playerid][pPayDayHad]);
                    SQL_UpdateInt(index, "CDPlayer",PlayerInfo[playerid][pCDPlayer]);
                    SQL_UpdateInt(index, "Dice",PlayerInfo[playerid][pDice]);
                    SQL_UpdateInt(index, "Screw",PlayerInfo[playerid][pScrew]);
                    SQL_UpdateInt(index, "Rope",PlayerInfo[playerid][pRope]);
                    SQL_UpdateInt(index, "AKmagazine",PlayerInfo[playerid][pAKmagazine]);
                    SQL_UpdateInt(index, "CSGmagazine",PlayerInfo[playerid][pCSGmagazine]);
                    SQL_UpdateInt(index, "Demagazine",PlayerInfo[playerid][pDemagazine]);
                    SQL_UpdateInt(index, "Cigars",PlayerInfo[playerid][pCigars]);
                    SQL_UpdateInt(index, "Sprunk",PlayerInfo[playerid][pSprunk]);
                    SQL_UpdateInt(index, "WT",PlayerInfo[playerid][pWT]);
                    SQL_UpdateInt(index, "WTc",PlayerInfo[playerid][pWTc]);
                    SQL_UpdateInt(index, "Bombs",PlayerInfo[playerid][pBombs]);
                    SQL_UpdateInt(index, "Scope",PlayerInfo[playerid][pScope]);
                    SQL_UpdateInt(index, "OwnsMask",PlayerInfo[playerid][pOwnsMask]);
                    SQL_UpdateInt(index, "Wins",PlayerInfo[playerid][pWins]);
                    SQL_UpdateInt(index, "Loses",PlayerInfo[playerid][pLoses]);
                    SQL_UpdateInt(index, "Tutorial",PlayerInfo[playerid][pTut]);
                    SQL_UpdateInt(index, "OnDuty",PlayerInfo[playerid][pOnDuty]);
                    SQL_UpdateInt(index, "Hospital",PlayerInfo[playerid][pHospital]);
                    SQL_UpdateInt(index, "Adjustable",PlayerInfo[playerid][pAdjustable]);
                    SQL_UpdateInt(index, "Married",PlayerInfo[playerid][pMarried]);
                    SQL_UpdateString(index, "MarriedTo",PlayerInfo[playerid][pMarriedTo]);
                    SQL_UpdateString(index, "NormalName",PlayerInfo[playerid][pNormalName]);
                    SQL_UpdateString(index, "AdminName",PlayerInfo[playerid][pAdminName]);
                    SQL_UpdateString(index, "HelperName",PlayerInfo[playerid][pHelperName]);
                    SQL_UpdateInt(index, "AdminDuty",PlayerInfo[playerid][pAdminDuty]);
                    SQL_UpdateString(index, "ContractBy",PlayerInfo[playerid][pContractBy]);
                    SQL_UpdateString(index, "IP",PlayerInfo[playerid][pIP]);
                    SQL_UpdateInt(index, "WantedLevel",PlayerInfo[playerid][pWantedLevel]);
                    SQL_UpdateInt(index, "NewbieMuted",PlayerInfo[playerid][pNewbieMuted]);
                    SQL_UpdateInt(index, "RHmuted",PlayerInfo[playerid][prhmuted]);
                    SQL_UpdateInt(index, "ReportMuted",PlayerInfo[playerid][pReportMuted]);
                    SQL_UpdateInt(index, "AdvertiseMuted",PlayerInfo[playerid][pAdvertiseMuted]);
                    SQL_UpdateInt(index, "SafeSpawn",PlayerInfo[playerid][pSafeSpawn]);
                    SQL_UpdateFloat(index, "SPos_x",PlayerInfo[playerid][pSPos_x]);
                    SQL_UpdateFloat(index, "SPos_y",PlayerInfo[playerid][pSPos_y]);
                    SQL_UpdateFloat(index, "SPos_z",PlayerInfo[playerid][pSPos_z]);
                    SQL_UpdateFloat(index, "SPos_r",PlayerInfo[playerid][pSPos_r]);
                    SQL_UpdateInt(index, "AidKit",PlayerInfo[playerid][pAidKit]);
                    SQL_UpdateInt(index, "HelperLevel",PlayerInfo[playerid][pHelper]);
                    SQL_UpdateInt(index, "Mask",HasBoughtMask[playerid]);
                    SQL_UpdateInt(index, "Blindfolds",PlayerInfo[playerid][pBlindfolds]);
                    SQL_UpdateInt(index, "Speedo",gSpeedo[playerid]);
                    SQL_UpdateInt(index, "Seeds",PlayerInfo[playerid][pSeeds]);
                    SQL_UpdateInt(index, "Famed", PlayerInfo[playerid][pFamed]);
                    SQL_Update(index);
                }
                else printf("Warning: Could not update '%s'.", PlayerName(playerid));
            }
            SavePlayerClothing(playerid);
        }
    }
    return 1;
}
this doesn't seem to be doing its job but can't figure out why:

pawn Code:
SQL_UpdateInt(index, "PlayerVehicleModel1",PlayerInfo[playerid][PlayerVehicleModel1]);
                    SQL_UpdateFloat(index, "PlayerVehicleFacing1",PlayerInfo[playerid][PlayerVehicleFacing1]);
                    SQL_UpdateInt(index, "PlayerVehicle1Color",PlayerInfo[playerid][pPlayerVehicle1Color]);
                    SQL_UpdateInt(index, "PlayerVehicle1Color2",PlayerInfo[playerid][pPlayerVehicle1Color2]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosX1",PlayerInfo[playerid][PlayerVehiclePosX1]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosY1",PlayerInfo[playerid][PlayerVehiclePosY1]);
                    SQL_UpdateFloat(index, "PlayerVehiclePosZ1",PlayerInfo[playerid][PlayerVehiclePosZ1]);
                    SQL_UpdateInt(index, "PlayerVehicle1PaintJob",PlayerInfo[playerid][PlayerVehicle1PaintJob]);
                    SQL_UpdateInt(index, "PlayerVehicle1Nos",PlayerInfo[playerid][PlayerVehicle1Nos]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot0",PlayerInfo[playerid][PlayerVehicle1ModSlot0]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot1",PlayerInfo[playerid][PlayerVehicle1ModSlot1]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot2",PlayerInfo[playerid][PlayerVehicle1ModSlot2]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot3",PlayerInfo[playerid][PlayerVehicle1ModSlot3]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot4",PlayerInfo[playerid][PlayerVehicle1ModSlot4]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot5",PlayerInfo[playerid][PlayerVehicle1ModSlot5]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot6",PlayerInfo[playerid][PlayerVehicle1ModSlot6]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot7",PlayerInfo[playerid][PlayerVehicle1ModSlot7]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot8",PlayerInfo[playerid][PlayerVehicle1ModSlot8]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot9",PlayerInfo[playerid][PlayerVehicle1ModSlot9]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot10",PlayerInfo[playerid][PlayerVehicle1ModSlot10]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot11",PlayerInfo[playerid][PlayerVehicle1ModSlot11]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot12",PlayerInfo[playerid][PlayerVehicle1ModSlot12]);
                    SQL_UpdateInt(index, "PlayerVehicle1ModSlot13",PlayerInfo[playerid][PlayerVehicle1ModSlot13]);



Re: Car Not Saving - Donvalley - 06.08.2013

does anyone know how SQL_UpdateInt works? here is the code:

pawn Code:
stock SQL_UpdateInt(index, field[], value)
{
    if ((index >= 0 && index < MAX_UPDATED_QUERIES) && E_QUERY_EXISTS[index])
    {
        new string[24];
        format(string, sizeof(string), "%d", value);
        return SQL_UpdateString(index, field, string);
    }
    return 0;
}
which then goes to this:

pawn Code:
stock SQL_UpdateString(index, field[], value[])
{
    if ((index >= 0 && index < MAX_UPDATED_QUERIES) && E_QUERY_EXISTS[index])
    {
        new string[128], File:file;
        format(string, sizeof(string), "`%s` = '%s', ", field, DB_Escape(value));
        if ((strlen(E_QUERY_DATA[index]) + strlen(string)) >= sizeof(E_QUERY_DATA[]))
        {
            new name[24];
            strunpack(name, E_QUERY_NAME[index]);
            printf("Warning: Update data buffer trying to exceed %d/%d characters (name: %s, field: %s)", strlen(E_QUERY_DATA[index]), sizeof(E_QUERY_DATA[]), name);
            return 0;
        }
        strins(E_QUERY_DATA[index], string, E_QUERY_POSITION[index]);
        file = fopen("fields.ini", io_readwrite);
        if (file || !fexist("fields.ini"))
        {
            new bool:found;
            if (!fexist("fields.ini"))
            {
                found = false;
                file = fopen("fields.ini", io_append);
            }
            else
            {
                while (fread(file, string, sizeof(string)))
                {
                    if (strcmp(string, field, false, strlen(field)) == 0)
                    {
                        found = true;
                        break;
                    }
                }
            }
            if (!found)
            {
                format(string, sizeof(string), "ALTER TABLE `Accounts` ADD COLUMN `%s` DEFAULT 0", field);
                db_query(AccountDB, string);
                fwrite(file, field);
                fwrite(file, "\r\n");
            }
            fclose(file);
        }
        return 1;
    }
    return 0;
}

is there anything wrong with these codes?


Re: Car Not Saving - Donvalley - 06.08.2013

bump. desperately need this fixed can anyone help'?


Re: Car Not Saving - Donvalley - 07.08.2013

bump, help please


Re: Car Not Saving - Donvalley - 08.08.2013

bump


Re: Car Not Saving - Donvalley - 09.08.2013

Will pay for someone to fix this...