mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-30 01:38:52 +00:00
Fix give weapon on esx:giveInventoryItem
This commit is contained in:
+1
-1
@@ -284,7 +284,7 @@ AddEventHandler('esx:giveInventoryItem', function(target, type, itemName, itemCo
|
||||
local weaponLabel = ESX.GetWeaponLabel(itemName)
|
||||
|
||||
if not targetXPlayer.hasWeapon(itemName) then
|
||||
local weaponNum, weapon = xPlayer.getWeapon(itemName)
|
||||
local weaponNum, weapon = sourceXPlayer.getWeapon(itemName)
|
||||
itemCount = weapon.ammo
|
||||
|
||||
sourceXPlayer.removeWeapon(itemName)
|
||||
|
||||
Reference in New Issue
Block a user