SA-MP Forums Archive
[HELP] Houses icons dont work - 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: [HELP] Houses icons dont work (/showthread.php?tid=512041)



[HELP] Houses icons dont work - JaydenD - 08.05.2014

This used to work back in 0.3x but it doesn't work anymore the problem is that when I create one house the icon shows there yeah but when I make another house the icon from the first house gets in the one I just created, the texts stays there but when I restart the server or shut it down both the icons and the text goes away but you can enter, other thing is that all that saves in the database but yeah for some reason this wont work, gm uses pretty much the ngg house system.


Re: [HELP] Houses icons dont work - JaydenD - 09.05.2014

Anyone


Re: [HELP] Houses icons dont work - Beckett - 09.05.2014

Mind showing your code?


Re: [HELP] Houses icons dont work - JaydenD - 13.05.2014

Код:
stock LoadHouses()
{
format(szQuery, sizeof(szQuery), "SELECT * FROM houses");
   HRPQuery(szQuery, THREAD_LOAD_HOUSES, INVALID_PLAYER_ID, g_MySQLConnections[0]);
return true;
}
stock SaveHouse(house)
{
if(HouseInfo[house][hInitiated] == 0)
   return true;

new szOwner[MAX_PLAYER_NAME];
mysql_real_escape_string(HouseInfo[house][hOwner], szOwner, g_MySQLConnections[0]);
format(szQuery, sizeof(szQuery), "UPDATE houses SET houseOwned = %d, houseLevel = %d, houseOwner = '%s', houseExteriorX = %f, houseExteriorY = %f, \
houseExteriorZ = %f, houseExteriorA = %f, houseInteriorX = %f, houseInteriorY = %f, houseInteriorZ = %f, houseInteriorA = %f, houseInteriorVW = %d",
HouseInfo[house][hOwned], HouseInfo[house][hLevel], szOwner, HouseInfo[house][hExteriorX],
HouseInfo[house][hExteriorY], HouseInfo[house][hExteriorZ], HouseInfo[house][hExteriorA], HouseInfo[house][hInteriorX], HouseInfo[house][hInteriorY],
HouseInfo[house][hInteriorZ], HouseInfo[house][hInteriorA], HouseInfo[house][hInteriorWorld]);

format(szQuery, sizeof(szQuery), "%s, houseLock = %d, houseRentable = %d, houseRentFee = %d, houseValue = %d, houseCash = %d, housePot = %d, houseCrack = %d, houseMaterials = %d, \
houseWeapons0 = %d, houseWeapons1 = %d, houseWeapons2 = %d, houseWeapons3 = %d, houseWeapons4 = %d, houseGunLocker = %d, houseCustomInterior = %d, \
houseCustomExterior = %d WHERE houseID = %d", szQuery, HouseInfo[house][hLock], HouseInfo[house][hRentable], HouseInfo[house][hRentFee],
HouseInfo[house][hValue], HouseInfo[house][hCash], HouseInfo[house][hPot], HouseInfo[house][hCrack], HouseInfo[house][hMaterials], HouseInfo[house][hWeapons][0],
HouseInfo[house][hWeapons][1], HouseInfo[house][hWeapons][2], HouseInfo[house][hWeapons][3], HouseInfo[house][hWeapons][4], HouseInfo[house][hGLUpgrade],
HouseInfo[house][hCustomInterior], HouseInfo[house][hCustomExterior], house);
HRPQuery(szQuery, THREAD_NO_RESULT, INVALID_PLAYER_ID, g_MySQLConnections[0]);
return true;
}