diff --git a/[core]/es_extended/server/main.lua b/[core]/es_extended/server/main.lua index 21d2f9fa..9e626d61 100644 --- a/[core]/es_extended/server/main.lua +++ b/[core]/es_extended/server/main.lua @@ -475,6 +475,9 @@ if not Config.CustomInventory then local weaponComponents = ESX.Table.Clone(weapon.components) local weaponTint = weapon.tintIndex + sourceXPlayer.removeWeapon(itemName) + targetXPlayer.addWeapon(itemName, itemCount) + if weaponTint then targetXPlayer.setWeaponTint(itemName, weaponTint) end @@ -485,9 +488,6 @@ if not Config.CustomInventory then end end - sourceXPlayer.removeWeapon(itemName) - targetXPlayer.addWeapon(itemName, itemCount) - if weaponObject.ammo and itemCount > 0 then local ammoLabel = weaponObject.ammo.label sourceXPlayer.showNotification(TranslateCap("gave_weapon_withammo", weaponLabel, itemCount, ammoLabel, targetXPlayer.name))