Coder Social home page Coder Social logo

ghzgarage / qb-inventory Goto Github PK

View Code? Open in Web Editor NEW

This project forked from qbcore-framework/qb-inventory

5.0 0.0 0.0 27.77 MB

Slot Based Inventory System Used With QB-Core :school_satchel:

License: GNU General Public License v3.0

Lua 53.40% JavaScript 28.87% HTML 10.11% CSS 7.62%

qb-inventory's Introduction

qb-inventory

Dependencies

Features

  • Stashes (Personal and/or Shared)
  • Vehicle Trunk & Glovebox
  • Weapon Attachments
  • Shops
  • Item Drops

Documentation

https://docs.qbcore.org/qbcore-documentation/qbcore-resources/qb-inventory

Installation

Manual

  • Download the script and put it in the [qb] directory.
  • Import qb-inventory.sql in your database
  • Add the following code to your server.cfg/resouces.cfg

Migrating from old qb-inventory

Database

Upload the new inventory.sql file to create the new inventories table

Use the provided migrate.sql file to migrate all of your saved inventory data from stashes, trunks, etc

Once complete, you can delete gloveboxitems stashitems and trunkitems tables from your database

CREATE TABLE IF NOT EXISTS `inventories` (
  `id` INT(11) NOT NULL AUTO_INCREMENT,
  `identifier` VARCHAR(50) NOT NULL,
  `items` LONGTEXT DEFAULT ('[]'),
  PRIMARY KEY (`identifier`),
  KEY `id` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4;

License

QBCore Framework
Copyright (C) 2021 Joshua Eger

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program.  If not, see <https://www.gnu.org/licenses/>

qb-inventory's People

Contributors

amantu-qbit avatar arsh939 avatar berkiebb avatar borreke0 avatar buntyverma69 avatar chatdisabled avatar christianbdev avatar d4isdavid avatar darknight2590 avatar evanillaa avatar flowdgodx avatar ghzgarage avatar gutsoo avatar ihyajb avatar itsanobrainer avatar jnktechstuff avatar jonezkti avatar josh-tf avatar kamuikody avatar macky4546 avatar mataskc avatar newtonzz avatar r0adra93 avatar s33g avatar stolk88 avatar tom-osborne avatar ushifty avatar viruspc2002 avatar z3rio avatar zfbx avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

qb-inventory's Issues

List of things I noticed while testing

The problem

  • If you drop your weapon while holding it, it stays in your hand
  • Networked entities for drops
  • Loading entire database table into lua table
  • qb-inventory:server:updateDrop does not update clients
  • Opening a dumpster triggers qb-inventory:server:openBin which doesn't exist
  • Server event to update core object?
  • If I have a stack of 100 and want to drop 1 I have to split it in half until 1 remains
  • Double clicking an item to consume it does not actually decrease one item
  • When holding a weapon, switching to another one just holsters it
  • /randomitems gives free random items
  • z or /hotbar throws an error
  • Inconsistent usage of RegisterCommand and QBCore.Commands.Add
  • When adding item(s) to an inventory exceeds the weight limit, the item(s) get deleted
  • Opening a vending machine triggers qb-inventory:server:openVending which doesn't exist
  • Receiving an item while the inventory is open doesn't update the inventory
  • Rightclick -> use, on an item doesn't decrease the item count, but does consume it
  • Excessive debug information in the console

Ideal solution

.

Alternative solutions

No response

Additional context

These tests were done on commit d1879f1

[BUG] Shop Bug

Summary

Can buy items in player inv

Reproduction

I found abug while editing the css , when you open a shop and buy an item you dont already have in your inventory, and rightclick it in the player inventory your still buying the item

Expected behavior

Nothing

Actual behavior

Nothing should happen

Additional context

2024-05-20.15-24-41.mp4

Last Updated

Today

Custom Resources

No just redesignet the css from inv

Resource Rename

no

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.