Please, post it!
Thanks.
Please, post it!
Thanks.
Hello, I have some problem, if I click to craft item nothing doing and i can´t close menu.Thanks for help
how we can change the script that only the mafia can see the crafting point or only mafia permission?
must be named esx_crafting or it wonât work
Look where it defines the blip and remove it. Or build in a way to show it only to one job
thanks
Not a problem mate !
it´s not working
Please can you share mate
I will grab the code when i get home today and post it
Alrighty ladies and gents. as mentioned i did find a way to modify the script to allow more than 1 qty output of a given recipe. itâs done with very little changes to the script and shouldnât cause any issues as long as you know what you are doing.
Now, the reason you are here
modify your âconfig.luaâ
Change your Item name from thisâŚ
["lockpick"] = {...
to this
["lockpick,4]
The â4â is where you would put the qty of how many you want to give the person.
modify your âserver.luaâ
Find the following line (roughly line 60)
AddEventHandler('salty_crafting:craftItem', function(ingredients)
and replace the function with this (roughly line 60 - 88)
AddEventHandler('salty_crafting:craftItem', function(ingredients) local _source = source local xPlayer = ESX.GetPlayerFromId(_source) local item = findRecipe(ingredients) if not item then TriggerClientEvent('esx:showNotification', _source, 'No recipe found with these ingredients') else if xPlayer ~= nil then if hasAllIngredients(xPlayer.inventory, Config.Recipes[item]) then for _,ingredient in pairs(Config.Recipes[item]) do if (ingredient.remove ~= nil and ingredient.remove) or (ingredient.remove == nil) then xPlayer.removeInventoryItem(ingredient.item, ingredient.quantity) end end if string.match(string.lower(item), "weapon_") then xPlayer.addWeapon(item, Config.WeaponAmmo) else string = item item, qty = string:match("([^,]+),([^,]+)") xPlayer.addInventoryItem(item, qty) end TriggerClientEvent('esx:showNotification', _source, '~y~Item Crafted: ~w~' .. itemLabel(item, xPlayer.inventory)) else TriggerClientEvent('esx:showNotification', _source, 'You do not have all of the ingredients') end end end end)
I can try solving any issues related, but there shouldnât be any
it works. THANKYOU
here is a idea not sure if possible but what are the chances of making a item work kinda like the crafting bench example could be like a Drug scale (once you have the item on you, you can then using the correct recipe maybe bag drugs,break down larger amounts to small amounts, so on so forth?
For everyone who has the âcan open but canât close the menuâ error (NUI callbacks) and want to rename the folder, hereâs the solution:
You want to rename the folder, for example, in salty_crafting123 you have to edit the HTML file.
Done. It worked for me.
I can open the UI via the pressing E, but i cant open the Shop?
Hello, I would like these buttons to be automatic, that is, if you leave the â+â button pressed and it is added, for example. the value is â0â, when you press the â+â, that 0 will automatically increase. I do not know if they understand me
https://gyazo.com/b5a82fb41b43422d25735e53b7f0b172
is there any way to make it so it displays all the craftable items and whats needed to craft them?
Any idea why when crafting WEAPON_PISTOL it crafts an item called pistol but said item is not even a weapon�
Like i buy a pistol from ammunation, and i craft a pistol⌠no ammo, not an equitpable item
i do ti, but doesnât work for me, when i press craft, nothing appens