SQLite BUD: nothing is being saved
#1

Help nothing is loading with my code and i do not know what is wrong......



PHP код:
public LoadPlayerData(playerid)
{
    if(
IsPlayerLoggedIn[playerid] == 1)
    {
        new 
File BUD::GetNameUID(GetName(playerid));
        
BUD::MultiGet(File"iiiiiiiiiiiffffiiiiiiiffiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii",
        
"Age"PlayerData[playerid][pAge],
        
"Vip"PlayerData[playerid][pVip],
        
"Admin"PlayerData[playerid][pAdmin],
        
"Money"PlayerData[playerid][pMoney],
        
"Level"PlayerData[playerid][pLevel],
        
"Gender"PlayerData[playerid][pGender],
        
"Accent"PlayerData[playerid][pAccent],
        
"Skin"PlayerData[playerid][pSkin],
        
"Carlic"PlayerData[playerid][pCarLic],
        
"BoatLic"PlayerData[playerid][pBoatLic],
        
"FlyLic"PlayerData[playerid][pFlyLic],
        
"PosX"PlayerData[playerid][pPosX],
        
"PosY"PlayerData[playerid][pPosY],
        
"PosZ"PlayerData[playerid][pPosZ],
        
"PosAngle"PlayerData[playerid][pPosAngle],
        
"Payday"PlayerData[playerid][pPayday],
        
"HadPayDay"PlayerData[playerid][pHadPayDay],
        
"Family"PlayerData[playerid][pFamily],
        
"Faction"PlayerData[playerid][pFaction],
        
"Tutorial"PlayerData[playerid][pTutorial],
        
"FactionRank"PlayerData[playerid][pFactionRank],
        
"Injured"PlayerData[playerid][pInjured],
        
"Health"PlayerData[playerid][pHealth],
        
"Armour"PlayerData[playerid][pArmour],
        
"VW"PlayerData[playerid][pVirtualWorld],
        
"Interior"PlayerData[playerid][pInterior],
        
"Job"PlayerData[playerid][pJob],
        
"BankBalance"PlayerData[playerid][pBankBalance],
        
"Weapon1"PlayerData[playerid][pWeapon][0],
        
"Weapon1Ammo"PlayerData[playerid][pWeaponAmmo][0],
        
"Weapon2"PlayerData[playerid][pWeapon][1],
        
"Weapon2Ammo"PlayerData[playerid][pWeaponAmmo][1],
        
"Weapon3"PlayerData[playerid][pWeapon][2],
        
"Weapon3Ammo"PlayerData[playerid][pWeaponAmmo][2],
        
"Weapon4"PlayerData[playerid][pWeapon][3],
        
"Weapon4Ammo"PlayerData[playerid][pWeaponAmmo][3],
        
"Weapon5"PlayerData[playerid][pWeapon][4],
        
"Weapon5Ammo"PlayerData[playerid][pWeaponAmmo][4],
         
"Weapon6"PlayerData[playerid][pWeapon][5],
         
"Weapon6Ammo"PlayerData[playerid][pWeaponAmmo][5],
        
"Weapon7"PlayerData[playerid][pWeapon][6],
        
"Weapon7Ammo"PlayerData[playerid][pWeaponAmmo][6],
        
"Weapon8"PlayerData[playerid][pWeapon][7],
        
"Weapon8Ammo"PlayerData[playerid][pWeaponAmmo][7],
        
"Weapon9"PlayerData[playerid][pWeapon][8],
        
"Weapon9Ammo"PlayerData[playerid][pWeaponAmmo][8],
        
"Weapon10"PlayerData[playerid][pWeapon][9],
        
"Weapon10Ammo"PlayerData[playerid][pWeaponAmmo][9],
         
"Weapon11"PlayerData[playerid][pWeapon][10],
         
"Weapon11Ammo"PlayerData[playerid][pWeaponAmmo][10],
         
"Weapon12"PlayerData[playerid][pWeapon][11],
         
"Weapon12Ammo"PlayerData[playerid][pWeaponAmmo][11],
         
"Weapon13"PlayerData[playerid][pWeapon][12],
         
"Weapon13Ammo"PlayerData[playerid][pWeaponAmmo][12],
         
"PRadio"PlayerData[playerid][pPRadio],
         
"PRadioFreq"PlayerData[playerid][pPRadioFreq],
         
"CigarSticks"PlayerData[playerid][pCigar],
         
"WineBottles"PlayerData[playerid][pWine]
        );
      }
    return 
1;
}
public 
ResetPlayerData(playerid)
{
    
PlayerData[playerid][pAge] = 0;
    
PlayerData[playerid][pVip] = 0;
    
PlayerData[playerid][pAdmin] = 0;
    
PlayerData[playerid][pMoney] = 0;
    
PlayerData[playerid][pLevel] = 0;
    
PlayerData[playerid][pGender] = 0;
    
PlayerData[playerid][pAccent] = 1;
    
PlayerData[playerid][pSkin] = 0;
    
PlayerData[playerid][pCarLic] = 1;
    
PlayerData[playerid][pBoatLic] = 0;
    
PlayerData[playerid][pFlyLic] = 0;
    
PlayerData[playerid][pPosX] = 0.0000;
    
PlayerData[playerid][pPosY] = 0.0000;
    
PlayerData[playerid][pPosZ] = 0.0000;
    
PlayerData[playerid][pPosAngle] = 0.0000;
    
PlayerData[playerid][pPayday] = 0;
    
PlayerData[playerid][pHadPayDay] = 0;
    
PlayerData[playerid][pFamily] = 0;
    
PlayerData[playerid][pFaction] = 0;
    
PlayerData[playerid][pTutorial] = 0;
    
PlayerData[playerid][pFactionRank] = 0;
    
PlayerData[playerid][pInjured] = 0;
    
PlayerData[playerid][pHealth] = 100.0;
    
PlayerData[playerid][pArmour] = 0.0;
    
PlayerData[playerid][pVirtualWorld] = 0;
    
PlayerData[playerid][pInterior] = 0;
    
PlayerData[playerid][pJob] = 0;
    
PlayerData[playerid][pBankBalance] = 0;
       
PlayerData[playerid][pWeapon][0] = 0;
    
PlayerData[playerid][pWeaponAmmo][0] = 0;
    
PlayerData[playerid][pWeapon][1] = 0;
    
PlayerData[playerid][pWeaponAmmo][1] = 0;
    
PlayerData[playerid][pWeapon][2] = 0;
    
PlayerData[playerid][pWeaponAmmo][2] = 0;
    
PlayerData[playerid][pWeapon][3] = 0;
    
PlayerData[playerid][pWeaponAmmo][3] = 0;
    
PlayerData[playerid][pWeapon][4] = 0;
    
PlayerData[playerid][pWeaponAmmo][4] = 0;
    
PlayerData[playerid][pWeapon][5] = 0;
    
PlayerData[playerid][pWeaponAmmo][5] = 0;
    
PlayerData[playerid][pWeapon][6] = 0;
    
PlayerData[playerid][pWeaponAmmo][6] = 0;
    
PlayerData[playerid][pWeapon][7] = 0;
    
PlayerData[playerid][pWeaponAmmo][7] = 0;
    
PlayerData[playerid][pWeapon][8] = 0;
    
PlayerData[playerid][pWeaponAmmo][8] = 0;
    
PlayerData[playerid][pWeapon][9] = 0;
    
PlayerData[playerid][pWeaponAmmo][9] = 0;
    
PlayerData[playerid][pWeapon][10] = 0;
    
PlayerData[playerid][pWeaponAmmo][10] = 0;
    
PlayerData[playerid][pWeapon][11] = 0;
    
PlayerData[playerid][pWeaponAmmo][11] = 0;
    
PlayerData[playerid][pWeapon][12] = 0;
    
PlayerData[playerid][pWeaponAmmo][12] = 0;
    
PlayerData[playerid][pPRadio]  = 0;
    
PlayerData[playerid][pPRadioFreq]  = 0;
    
PlayerData[playerid][pCigar]  = 0;
    
PlayerData[playerid][pWine]  = 0;
    return 
1;
}
public 
SavePlayerData(playerid)
{
    if(
IsPlayerLoggedIn[playerid] == 1)
    {
        new 
Float:PHealthFloat:PArmour;
        new 
VWorld GetPlayerVirtualWorld(playerid);
           new 
Interior GetPlayerInterior(playerid);
           new 
Float:PosXFloat:PosYFloat:PosZFloat:PosAngle;
           new 
Money GetPlayerMoney(playerid);
           new 
Level GetPlayerScore(playerid);
           new 
Skin GetPlayerSkin(playerid);
        
GetPlayerHealth(playeridPHealth);
        
GetPlayerArmour(playeridPArmour);
        
GetPlayerPos(playeridPosXPosYPosZ);
         
GetPlayerFacingAngle(playeridPosAngle);
        for (new 
013i++)
        {
            
GetPlayerWeaponData(playeridiPlayerData[playerid][pWeapon][i], PlayerData[playerid][pWeaponAmmo][i]);
          }
        new 
File BUD::GetNameUID(GetName(playerid));
           
BUD::MultiSet(File"iiiiiiiiiiiffffiiiiiiiffiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiii",
        
"Age"PlayerData[playerid][pAge],
        
"Vip"PlayerData[playerid][pVip],
        
"Admin"PlayerData[playerid][pAdmin],
        
"Money"Money,
        
"Level"Level,
        
"Gender"PlayerData[playerid][pGender],
        
"Accent"PlayerData[playerid][pAccent],
        
"Skin"Skin,
        
"Carlic"PlayerData[playerid][pCarLic],
        
"BoatLic"PlayerData[playerid][pBoatLic],
        
"FlyLic"PlayerData[playerid][pFlyLic],
        
"PosX"PosX,
        
"PosY"PosY,
        
"PosZ"PosZ,
        
"PosAngle"PosAngle,
        
"Payday"PlayerData[playerid][pPayday],
        
"HadPayDay"PlayerData[playerid][pHadPayDay],
        
"Family"PlayerData[playerid][pFamily],
        
"Faction"PlayerData[playerid][pFaction],
        
"Tutorial"PlayerData[playerid][pTutorial],
        
"FactionRank"PlayerData[playerid][pFactionRank],
        
"Injured"PlayerData[playerid][pInjured],
        
"Health"PHealth,
        
"Armour"PArmour,
        
"VW"VWorld,
        
"Interior"Interior,
        
"Job"PlayerData[playerid][pJob],
        
"BankBalance"PlayerData[playerid][pBankBalance],
        
"Weapon1"PlayerData[playerid][pWeapon][0],
        
"Weapon1Ammo"PlayerData[playerid][pWeaponAmmo][0],
        
"Weapon2"PlayerData[playerid][pWeapon][1],
        
"Weapon2Ammo"PlayerData[playerid][pWeaponAmmo][1],
        
"Weapon3"PlayerData[playerid][pWeapon][2],
        
"Weapon3Ammo"PlayerData[playerid][pWeaponAmmo][2],
        
"Weapon4"PlayerData[playerid][pWeapon][3],
        
"Weapon4Ammo"PlayerData[playerid][pWeaponAmmo][3],
        
"Weapon5"PlayerData[playerid][pWeapon][4],
        
"Weapon5Ammo"PlayerData[playerid][pWeaponAmmo][4],
         
"Weapon6"PlayerData[playerid][pWeapon][5],
         
"Weapon6Ammo"PlayerData[playerid][pWeaponAmmo][5],
        
"Weapon7"PlayerData[playerid][pWeapon][6],
        
"Weapon7Ammo"PlayerData[playerid][pWeaponAmmo][6],
        
"Weapon8"PlayerData[playerid][pWeapon][7],
        
"Weapon8Ammo"PlayerData[playerid][pWeaponAmmo][7],
        
"Weapon9"PlayerData[playerid][pWeapon][8],
        
"Weapon9Ammo"PlayerData[playerid][pWeaponAmmo][8],
        
"Weapon10"PlayerData[playerid][pWeapon][9],
        
"Weapon10Ammo"PlayerData[playerid][pWeaponAmmo][9],
         
"Weapon11"PlayerData[playerid][pWeapon][10],
         
"Weapon11Ammo"PlayerData[playerid][pWeaponAmmo][10],
         
"Weapon12"PlayerData[playerid][pWeapon][11],
         
"Weapon12Ammo"PlayerData[playerid][pWeaponAmmo][11],
         
"Weapon13"PlayerData[playerid][pWeapon][12],
         
"Weapon13Ammo"PlayerData[playerid][pWeaponAmmo][12],
         
"PRadio"PlayerData[playerid][pPRadio],
         
"PRadioFreq"PlayerData[playerid][pPRadioFreq],
         
"CigarSticks"PlayerData[playerid][pCigar],
         
"WineBottles"PlayerData[playerid][pWine]
        );
    }
    return 
1;

Reply


Messages In This Thread
SQLite BUD: nothing is being saved and loaded - by Ryan_Obeles - 23.04.2013, 05:33
Re: SQLite BUD: nothing is being saved - by Ryan_Obeles - 23.04.2013, 06:21
Re: SQLite BUD: nothing is being saved - by DaTa[X] - 23.04.2013, 06:22
Re: SQLite BUD: nothing is being saved - by Ryan_Obeles - 23.04.2013, 06:26
Re: SQLite BUD: nothing is being saved - by DaTa[X] - 23.04.2013, 06:36
Re: SQLite BUD: nothing is being saved - by Ryan_Obeles - 23.04.2013, 06:40
Re: SQLite BUD: nothing is being saved - by Slice - 23.04.2013, 07:10
Re: SQLite BUD: nothing is being saved - by Ryan_Obeles - 23.04.2013, 07:13
Re: SQLite BUD: nothing is being saved - by Slice - 23.04.2013, 07:14
Re: SQLite BUD: nothing is being saved - by Ryan_Obeles - 23.04.2013, 07:15

Forum Jump:


Users browsing this thread: 3 Guest(s)