[RELEASE] Advanced truck inventory for ESX (black money, weapons, items)

true, and not only money but also weapons and etc.

Yup kind of annoying, because this script was almost perfect for my server :confused:

2 Likes

so guys i have a problem that hasnt got to do with this theme but i realy need help.
I have a empty inventory on my player so i tried to get some medickits. No medic poped up in the inventory it only sad that i had to much on me… but the inv is empty… is the error in esx_ambulancejob or somwhere else?

Would there be a way to add multiple weapons of the same type, kind of like how the esx_policejob armory works? I’m also unable to add items like knives and flashlights which hold no ammo. Any help would be appreciated.

which file would I add this in?.

I have a problem with the script now… If i close my door and reopen it, I am no longer able to use the trunk…

I am using ESX, anybody has that problem ?

anyone able to help me with this? Is this even possible?

If I press L no menu opens

Help me

https://hastebin.com/elekagomar.xml

got that error:
lua5.3: source_file.lua:106: unexpected symbol near ‘=’

Someone see the error? Sorry I must be blind…thx!

none of my files are colled “source_file.lua” lol :’)

Oh sorry, that is a tool I use if I’m blind like this time @Jager_Bom I will send you (edit this post) the Console error

Did anyone found a fix for the script ?
Lets say… I put 10,000$ of black money inside the trunk.

Now my friend and I look into the trunk and try to take out 10,000$ at the same time while pressing OK, it will give the 10,000$ to both of us so now we have 20,000$ and we can just redo this glitch over and over and get more than 5 millions black money under 30 minutes

there is bigger problem than 2 plaers look inside the trunk. If u press enter a lot of times after puting mth inside u will duplicate items 5x times or more.

that is not a problem, you just have to make sure that you will close the UI after you put a item inside

Did you find out How?

This script works like 70% for me. It lets me open a trunk and gives me the menu to put items in it. But when i try to put an item in the trunk i get this error:

[ERROR] [MySQL] An error happens on MySQL for query "INSERT INTO truck_inventory (item,count,plate,name,itemt,owned) VALUES (@item,@qty,@plate,@name,@itemt,@owned) ON DUPLICATE KEY UPDATE count=count+ @qty {@item=bread;@itemt=0;@plate=00GCL987;@qty=1;@name=Br├╕d}": Column 'owned' cannot be null

Has anyone figured out a way to fix this? Also if anyone knows of a script that does work could you please reply to this with a link or pm me a link to a working trunk storing script. Thanks in advance! :slight_smile:

does anyone know how to fix the trunk from starting to open but immediately closing?

wehicle is owned means taht when you buy at vehicleshop you set owned on 1 otherwise all cars spawn by jobs are 0
so that if you reboot the server all trucks that are not owned cars will be deleted. so it will save space in your db

Yes but thats the error i get from the trunk script.

Hey i’m using some emojis in labels of my items , but with this script the encoding mark " ? " before each item , any way to force the label of my item table items stock in the truck inventory table name ?