Jump to content
Fivem-DEV.cz
  • 0
Sign in to follow this  
_Brumča_ KEKW

Error s Police skladem.

Question

Ahoj, potrebuji pomoc s police skladem... Zkoušel jsem všechny možnosti jak to fixnout ale nevím jak. Poradíte mi ? 
Zde máteimage.thumb.png.74a1c27be72e93c52764b6eb9f2cbcad.png screen

Share this post


Link to post
Share on other sites

5 answers to this question

Recommended Posts

  • 0
function OpenWeaponComponentShop(components, weaponName, parentShop)
	ESX.UI.Menu.Open('default', GetCurrentResourceName(), 'armory_buy_weapons_components', {
		title    = _U('armory_componenttitle'),
		align    = 'right',
		elements = components
	}, function(data, menu)
		if data.current.hasComponent then
			ESX.ShowNotification(_U('armory_hascomponent'))
		else
			ESX.TriggerServerCallback('esx_policejob:buyWeapon', function(bought)
				if bought then
					if data.current.price > 0 then
						ESX.ShowNotification(_U('armory_bought', data.current.componentLabel, ESX.Math.GroupDigits(data.current.price)))
					end

					menu.close()
					parentShop.close()
					OpenBuyWeaponsMenu()
				else
					ESX.ShowNotification(_U('armory_money'))
				end
			end, weaponName, 2, data.current.componentNum)
		end
	end, function(data, menu)
		menu.close()
	end)
end

Přepiš celou funkci a máš to vyřešené :) Není zač <3 

Share this post


Link to post
Share on other sites
  • 0
On 10/5/2021 at 2:31 AM, pikachucz said:

function OpenWeaponComponentShop(components, weaponName, parentShop)
	ESX.UI.Menu.Open('default', GetCurrentResourceName(), 'armory_buy_weapons_components', {
		title    = _U('armory_componenttitle'),
		align    = 'right',
		elements = components
	}, function(data, menu)
		if data.current.hasComponent then
			ESX.ShowNotification(_U('armory_hascomponent'))
		else
			ESX.TriggerServerCallback('esx_policejob:buyWeapon', function(bought)
				if bought then
					if data.current.price > 0 then
						ESX.ShowNotification(_U('armory_bought', data.current.componentLabel, ESX.Math.GroupDigits(data.current.price)))
					end

					menu.close()
					parentShop.close()
					OpenBuyWeaponsMenu()
				else
					ESX.ShowNotification(_U('armory_money'))
				end
			end, weaponName, 2, data.current.componentNum)
		end
	end, function(data, menu)
		menu.close()
	end)
end

Přepiš celou funkci a máš to vyřešené :) Není zač <3 

Ahoj, díky, již mám problem stímhle image.thumb.png.96ae9ec203420c130460b02ae42a3241.png

image.png.a57c447a58fffd4a44e92a96a02bfa55.png

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

Our partners

rcore.cz
K4mb1
SLTH
×
×
  • Create New...