Hello, this project is for a GTA Roleplay Server. The basic menu framework has been done, but all my inventory items are stored in a couchdb. Example
{
"_id": "e0fbcd190dd40c000bbe698b90003730",
"_rev": "302-4944dc5d11d06dd58093db6c7d290cb9",
"weapons": [],
"identifier": "steam:110000106e0c14b",
"is_cop": 9,
"inventory": [],
"last_name": "Prowell",
"first_name": "Xaiver",
"cash": 2921084,
"gender": "Male",
"dirty": 0,
"bank": 190201398,
"licenses": [
"Driver's License"
],
"characteristics": {
"0": 19,
"2": [
4,
3
],
"3": 4,
"4": [
3,
2
],
"6": 4,
"8": 1,
"11": [
3,
2
]
},
"is_ems": 0,
"vehicles": {
"1": {
"hash": 272929391,
"model": "Pegassi Tempesta",
"customization": [],
"stored": false,
"impounded": false,
"plate": "1628654"
},
"hash": -1297672541,
"model": "Dinka Jester",
"customization": [],
"stored": true,
"impounded": false,
"plate": "6286549"
}
}
Inventory being the table that I need for this inventory system.
I need a loop to be done to create buttons under the inventory sub menu. The basis is made up of html, js, and lua. The CSS is already made.
Image: [login to view URL]
Basically you will click on the Inventory Button, and it will then create the buttons in the submenu through a loop finding your inventory items and the amount of them you have. And then you will be able to click on that inventory item and choose to use it.