jimathy / jim-shops

QBCore QB-Menu based replacement for qb-shops
53 stars 42 forks source link

Weapon License + Jim Shops #32

Open lak1z-azk opened 1 year ago

lak1z-azk commented 1 year ago

Tried few ways to achieve a posibility to buy a weapon, having a Weapon License, but seems that if for Ammunnition you set "true" for required license

example: { name = "weapon_vintagepistol", price = math.random(PistolMin, PistolMax), amount = 5, requiresLicense = true },

In game player can't see the weapon in the shop. image

And in his inventory he has a weapon license image

For me as an admin I see everything, but players can't buy the items, that are marked with the license part set as True.

Also as I can see in the server.lua image it is defined in the same way as I have in items.lua

Appreciate for any help with this. Maybe I'm missing something..

Thanks!

Dezavu-GR commented 9 months ago

change: "requiresLicense = true" to: "requiresLicense = {"weapon"}, requiresItem = {"weaponlicense"}"

example: { name = "weapon_vintagepistol", price = math.random(PistolMin, PistolMax), amount = 5,requiresLicense = {"weapon"}, requiresItem = {"weaponlicense"} },