Esx_weashop with weapon clip

Open the sql file and remove the very first line that says “use essentialmode”

It’s happening because your database isn’t actually named essentialmode. the line isn’t needed.

1 Like

thank you very much

hey love the script been looking for it for some time now! And i finally found it. ive added the updated info for sql and now when i go to the gunshop i get nothing. ive paid for my license but when i click back in to get some guns i see it blank

this is what my database look like. so im not sure why :frowning:

I’ve got a serious issue I keep trying to update prices or rearrange how the weapons are listed and nothing ever updates any help?

Hey, i got your mod, but i have a major issue, where i cant see any item in the shop… i added this:

INSERT INTO weashops (name, item, price) VALUES
(‘GunShop’,‘WEAPON_FLASHLIGHT’,100),
(‘GunShop’,‘WEAPON_BAT’,400),
(‘GunShop’,‘WEAPON_KNIFE’,700),
(‘GunShop’,‘WEAPON_PISTOL’,5000),
(‘GunShop’,‘WEAPON_HEAVYPISTOL’,10000),
(‘GunShop’,‘WEAPON_PUMPSHOTGUN’,11000),
(‘GunShop’,‘WEAPON_SAWNOFFSHOTGUN’,13000),

But still it’s is empty in game

2 Likes

you find the issue? I have the same problem

Me too

i found that removing the whole weaponshop table from the database then adding the new one (weashops.sql) it works fine.

BACK YOUR DATABASE UP FIRST JUST INCASE

so you mean we must just delete old tables in db and all be fine?

that worked for me yea just make sure you do back it up first. Only delete the weaponshop table thats already in there though

1 Like

Can someone please give me the code for Armor so i can put it in the store. i have been looking everywhere can’t seem to find it.

Error running system event handling function for resource esx_weashops: citizen:/scripting/lua/scheduler.lua:41: Failed to execute thread: @esx_weashops/server/main.lua:122: attempt to index a nil value (local 'sourceItem')
stack traceback:
        @esx_weashops/server/main.lua:122: in upvalue 'handler'
        citizen:/scripting/lua/scheduler.lua:219: in function <citizen:/scripting/lua/scheduler.lua:218>
stack traceback:
        [C]: in function 'error'
        citizen:/scripting/lua/scheduler.lua:41: in field 'CreateThreadNow'
        citizen:/scripting/lua/scheduler.lua:218: in function <citizen:/scripting/lua/scheduler.lua:182>

Solution?

The bulletproofvest with armor isnt a weapon.

oh so only weapons can be stored. okay thanks for the response.

Blackweashop

remove pay black money

normal money please !

15575778784995501230301710277787|281x500

You have to replace

			if xPlayer.getAccount('black_money').money >= price then
				xPlayer.removeAccountMoney('black_money', price)
				xPlayer.addWeapon(weaponName, 42)

by

if xPlayer.getMoney() >= price then
				xPlayer.removeMoney(price)
				xPlayer.addWeapon(weaponName, 42)

in main.lua file server

Tank you!

1 Like

Get kind same

loaded resoruces, go to weapon shop, everythingh works to buy accept Ammo, dosent happend anything in game or errors, just spit this errors in console

Error running system event handling function for resource esx_jb_weashops: citizen:/scripting/lua/scheduler.lua:41: Failed to execute thread: citizen:/scripting/lua/MessagePack.lua:830: missing bytes
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/MessagePack.lua:830: in method ‘underflow’
citizen:/scripting/lua/MessagePack.lua:465: in field ‘any’
citizen:/scripting/lua/MessagePack.lua:860: in field ‘unpack’
citizen:/scripting/lua/scheduler.lua:626: in field ‘addInventoryItem’
@esx_jb_weashops/server/main.lua:107: in upvalue ‘handler’
citizen:/scripting/lua/scheduler.lua:219: in function citizen:/scripting/lua/scheduler.lua:218
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:41: in field ‘CreateThreadNow’
citizen:/scripting/lua/scheduler.lua:218: in function citizen:/scripting/lua/scheduler.lua:182
Error running call reference function for resource es_extended: citizen:/scripting/lua/scheduler.lua:403: @es_extended/server/classes/player.lua:317: attempt to index a nil value (local ‘item’)
stack traceback:
@es_extended/server/classes/player.lua:317: in upvalue ‘ref’
citizen:/scripting/lua/scheduler.lua:389: in function citizen:/scripting/lua/scheduler.lua:388
[C]: in function ‘xpcall’
citizen:/scripting/lua/scheduler.lua:388: in function citizen:/scripting/lua/scheduler.lua:387
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:403: in function citizen:/scripting/lua/scheduler.lua:372
Error running system event handling function for resource esx_jb_weashops: citizen:/scripting/lua/scheduler.lua:41: Failed to execute thread: citizen:/scripting/lua/MessagePack.lua:830: missing bytes
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/MessagePack.lua:830: in method ‘underflow’
citizen:/scripting/lua/MessagePack.lua:465: in field ‘any’
citizen:/scripting/lua/MessagePack.lua:860: in field ‘unpack’
citizen:/scripting/lua/scheduler.lua:626: in field ‘addInventoryItem’
@esx_jb_weashops/server/main.lua:107: in upvalue ‘handler’
citizen:/scripting/lua/scheduler.lua:219: in function citizen:/scripting/lua/scheduler.lua:218
stack traceback:
[C]: in function ‘error’
citizen:/scripting/lua/scheduler.lua:41: in field ‘CreateThreadNow’
citizen:/scripting/lua/scheduler.lua:218: in function citizen:/scripting/lua/scheduler.lua:182
Sending heartbeat to live-internal.fivem.net:30110

Well i think it happened because you haven’t imported the sql database yet.
You need to add the item ‘clip’ to your items database!

one guy posted something about it on top off the topic go look