Jump to content

Furniture for my house system


darhal

Recommended Posts

Hi all I finish my house system a long time ago in 2014 and with mta 1.4 new functions I'd like to make furnture system for the house system so the problem was how to save objects that you buy for your house using sql ??

It will be a big database with lag on players join and quit also making many objects will influance on the FPS so how to resolve all this ? Any suggetions please

Regards ,

Link to comment

As a simple solution: store everything in a table (objects positions, model IDs, etc.), convert it to JSON string and save it in your database. When someone gets inside of a house, extract furniture data from the database (I mean that JSON string), send it to the client, convert it to a normal table (using fromJSON()), loop through it and create objects client-side, so it won't affect other players.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...