i-kulgu / qb-inventory-decay

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

qb-inventory with decay system and lj-inventory look

If you like my work and want to support me : ko-fi

For issues and enhancements you can send a PR or contact me from my Discord channel!
Team Hi-Dev

Runs at ~ 0.00 to 0.01 ms if you have more optimization suggestions feel free to reach out


Inventory is up to date with the latest qb-inventory fixes and dupe

Dependencies

How to install

  • Download source files from github
  • Drag source files into your resources folder
  • Rename folder to qb-inventory

image

TO DO

you need to add a decay and created value in your qb-core/shared/items for all items, the decay is set to be the days the item lasts

-- created = this will get filled in with the time when it's created, just leave this
-- decay = amount of days that an item will decay
-- delete = choice whether to remove the item when it's decayed or not
["created"] = nil, ["decay"] = 28.0, ["delete"] = true

Example:
['sandwich'] = {['name'] = 'sandwich', ['label'] = 'Sandwich', ['weight'] = 200, ['type'] = 'item', ['image'] = 'sandwich.png', ['unique'] = false, ['useable'] = true, ['shouldClose'] = true,	['combinable'] = nil, ['description'] = 'Nice bread for your stomach', ["created"] = nil, ["decay"] = 3.0, ["delete"] = true},

In this example our sandwich will decay in 3 days and removed when used.

Previews

full inventory


Credits


Issues and Suggestions

Please use the GitHub issues system to report issues or make suggestions, when making suggestion, please keep [Suggestion] in the title to make it clear that it is a suggestion.

About

License:GNU General Public License v3.0


Languages

Language:Lua 52.6%Language:JavaScript 38.2%Language:CSS 6.0%Language:HTML 3.1%