NVM Housing System [esx]

I think the script’s recording of the height might be a bit out. I have to adjust the height in the sql of each garage to see the garage marker. Other than that, great work!

how much you need to add for the right height? 1.0 ? And it’s only for the garage part or the house part too

hey hope all is well i add the script now its running but im getting error messages

Table ‘zap1228904-1.nvm_houses’ doesn’t exist
Query: SELECT id, house_coords FROM nvm_houses WHERE oidentifier = ? OR id IN (SELECT house_id FROM nvm_houses_keys WHERE identifier = ?)

hey, i think you’re running the old sql, after the the first update, i changed the sql coloumns names, and added more coloumns, so just delete the nvm_house, and nvm_house_keys, redownload the script from github, and upload that sql, and if everything ok, it’s gonna work

1 Like

I edit the heading and then I can see the garage at the correct height. Makes no sense to me. If I use the system as it is, the garage will not be there at all, until I change the heading in the “H” column.

Is there a way to add more interiors?

Yes there is but you need to write in the files, but I will help you.

in main/client follow this:
after line 648 in the GetInterior function - this is where you will teleport where will be the the exit of the house

[“8”] = {x = , y = , z = },
you can always add more to this, make sure always increase the number, dont be the same, and dont forget the coma,

after that: after line 662 in the GetStorage function - this is where the house stash location will be

[“8”] = {x = , y = , z = }, - make sure that the number is the same with the interior number, this is more like a key, and dont forget the coma

in nui/index.html follow this:
after line 36 in the interio-select - this will make the interior selectable in the menu.

'<'option value=“8”>8
make sure that the number is same as you write it in the client and remove the ’ in the first <, (I need to write here like this otherwise don’t show it properly)
_
copy and paste it after the 110 line

if you want to add the preview then add a photo in the nui/images
makes sure that the image formatum is JPG othewise it’s not gona work

I hope it’s clearer then it looks XD, but if you need more help, feel free to ask, and I will do the best to help!

1 Like

And I think I will make it easier in the future to use only the config.lua!

Oh and with the garage system, I don’t quite understand the main proble, so if you willing to help the show it with a video, or pictures, the problem it self, i will look after that too!

1 Like

House placement works fine, garage just doesn’t spawn.

oooh I see, need a script reset, or a player relog, cause the garage shown only for the player who own the house, anyone else can’t see it, and because I only fetch the player one time, that is why the garage will not update instant

Ahhhh now I see it. All good! Thanks so much. I didn’t realise a relog was required.
Only issue now is, when I spawn the car I’m inside it, but not inside it. Does damage to the car and I have to press F to enter the vehicle, which I is a bit janky.


Caused a fuel tank rupture.

Updatet Client.lua. Added a little wait in line 624. It should solve the problem, if not I will look deeper in that problem

Ok, so I just need to upload the client.lua?

i ran the sql in heidisql. i still get this:
[ script:oxmysql] Table ‘fizgigs.nvm_houses’ doesn’t exist
[ script:oxmysql] Error: nvm_house was unable to execute a query!
[ script:oxmysql] Query: SELECT * FROM nvm_houses
[ script:oxmysql]

the table is showing in my database.

yes, should be fine, if not, then try to adjust the wait propably go for 75 or even 100, but it should not have a problem

Make sure, it’s in the correct database, which is your server using, make sure your oxmysql, and mysql-async are up to date, otherwise I really don’t know, cause the error is saying that the the sql has been not uploaded

1 Like

well i got new problem when i put my items in storage and server restart is all gone and I got error

Hey! The error is about the garage part, make sure you write x, y and z koordinate.
For the storage part, it’s probably the sql, in the ox_inventory sql, extend the length of the owner.
image
the default value gonna be 55, try to increase it like up to 60 or even 70.

1 Like

Yeah, I fixed it when I added the house. I didn’t add the garage, yeah, and now it is giving an error. It’s not a problem, but when I put items in storage and restart the server, all the items are gone in storage!