12.07.2012, 13:19
OK,so I have scripted a house system(buy house,sell house,etc.) using as database system Y_INI.But to do this,I followed a tutorial,but the tutorial used MySQL for creating the DataBase.Well,nevermind,after struggling and modifying A LOT OF THINGS(The original tutorial was using commands,I used dialogs,the tutorial was using checkpoints,I used icons),I have a 99% working system,and the database rocks:
The only problem is when the server restarts,the house deletes(if the house was belonging to someone,it's again for sell),and I might have spotted the problem...This is the only piece of coded I wasn't able to convert because I have no idea how...:
How would look that in Y_INI?If you need an entire piece of my code,tell me...
Код:
[HouseInfo] Owner = [LSCS]Eddie SellPrice = 0 Interior = 5 TeleX = 1267.663208 TeleY = -781.323242 TeleZ = 1091.906250 EnterX = -2622.046630 EnterY = 375.950805 EnterZ = 6.156300 ExitX = 1261.278686 ExitY = -785.316711 ExitZ = 1091.906250 ForSell = 0
pawn Код:
format(fquery, sizeof(fquery), "SELECT houseowner FROM HOUSEINFO WHERE housename = '%s'", HouseName);