Ac-Shop

posted 24-01-2024 13:58 12.656 views 95 replies 35 Credits
WestRust
0 Posts
600 Credits
N/A Since
#1 12.656 views 95 replies


Full Fix Open Source
replies (20)
WestRust
301 Posts
600 Credits
Aug 2022 Since
#21
@@YehodAtias

Add the items you want to the markets from the config and as an extra example, you can look at markets numbered 12 and 13, they also have items.
YehodAtias
5 Posts
490 Credits
Oct 2023 Since
#22
how i fix this?

please tell

WestRust,
@@YehodAtias

Add the items you want to the markets from the config and as an extra example, you can look at markets numbered 12 and 13, they also hav...

[attachment removed]

the all name i knife[/attachment]
esplugin
31 Posts
856 Credits
Aug 2023 Since
#23
SCRIPT ERROR: @ac-shop/server/server.lua:97: attempt to call a nil value (field 'addInventoryItem')
WestRust
301 Posts
600 Credits
Aug 2022 Since
#24

YehodAtias,
how i fix this?

please tell

[attachment removed]

the all name i knife

This error is not from me, can you look at the item names in the config, I tested it on my friend and if we saw something like this, we would fix it.[/attachment]
WestRust
301 Posts
600 Credits
Aug 2022 Since
#25

esplugin,
SCRIPT ERROR: @ac-shop/server/server.lua:97: attempt to call a nil value (field 'addInventoryItem')

What is your inventory and in which infrastructure are you getting errors?
esplugin
31 Posts
856 Credits
Aug 2023 Since
#26
New QBCore lj-inventory bro :=)

WestRust,
What is your inventory and in which infrastructure are you getting errors?
WestRust
301 Posts
600 Credits
Aug 2022 Since
#27
It will be fixed if you change it with the lj inventory item giving event, or it may not be the required parameter, so can you make the necessary change by looking in another script?
esplugin
31 Posts
856 Credits
Aug 2023 Since
#28

WestRust,
It will be fixed if you change it with the lj inventory item giving event, or it may not be the required parameter, so can you make the necessary chan...

Yes ı fixed qbcore

local QBCore = exports['qb-core']:GetCoreObject()
RegisterNetEvent('ac-shop:pay')
AddEventHandler('ac-shop:pay', function(data)
local src = source
local xPlayer = QBCore.Functions.GetPlayer(src)
if data.payType == "cash" then
local money = xPlayer.PlayerData.money['cash']
if money >= data.price then
xPlayer.Functions.RemoveMoney('cash', data.price, "Shops")
AC.Success()
for k,v in pairs(data.cartArr) do
xPlayer.Functions.AddItem(v.itemname, tonumber(v.count))
end
else
AC.Error()
end
else
local bankMoney = xPlayer.PlayerData.money['bank']
if bankMoney >= data.price then
xPlayer.Functions.RemoveMoney('bank', data.price, "Shops")
AC.Success()
for k,v in pairs(data.cartArr) do
xPlayer.Functions.AddItem(v.itemname, tonumber(v.count))
end
else
AC.Error()
end
end
end)
WestRust
301 Posts
600 Credits
Aug 2022 Since
#29

esplugin,
Yes ı fixed qbcore

local QBCore = exports['qb-core']:GetCoreObject()
RegisterNetEvent('ac-shop:pay')
AddEventHandler('ac-...

Thanks for sharing. If anyone else gets the same error, they can use this.
callisto
428 Posts
1,260 Credits
Jul 2022 Since
#30
[attachment removed]

working but if i buy it doesn't send to my inventory[/attachment]
WestRust
301 Posts
600 Credits
Aug 2022 Since
#31

callisto,
[attachment removed]

working but i get the bug an item name at shoping chart, and if i buy it doesn't send to my inventory

Use the item giving function suitable for your inventory, whatever infrastructure you are using, make that code by looking at the item giving function in your script.[/attachment]
jokerfleck
118 Posts
47 Credits
Apr 2022 Since
#32

WestRust,
I added the new link, do not forget to select the discount from the new link and the framework from the config.

i have test it and it works thank you very much but i have pay double can you give me credits back please
garix371
136 Posts
283 Credits
Aug 2022 Since
#33
Good share bro cheers good one this
WestRust
301 Posts
600 Credits
Aug 2022 Since
#34
esx or qb open source +rep
Taifun20
125 Posts
47 Credits
Mar 2022 Since
#35
Nice thanks man for this share
jokerfleck
118 Posts
47 Credits
Apr 2022 Since
#36

WestRust,
esx or qb open source +rep

can you give me please my credits back i have pay double that would be nice
ajey_00
3 Posts
292 Credits
Dec 2023 Since
#37

callisto,
[attachment removed]

working but i get the bug an item name at shoping chart, and if i buy it doesn't send to my inventory

CAN YOU HELP ME mm[/attachment]
Soleuco_
17 Posts
24 Credits
Jan 2024 Since
#38
Thanks for sharing but a little expensive
MahmoudiTech
471 Posts
3,757 Credits
Dec 2021 Since
#39
wow nice thanks, looks so clean
discocompanyagency
552 Posts
79 Credits
Nov 2022 Since
#40
Very nice and very good job

You must be logged in to reply

Login Register