Skip to content

Commit

Permalink
fix(server/items): allow stunguns to have a serial
Browse files Browse the repository at this point in the history
  • Loading branch information
thelindat committed Apr 19, 2022
1 parent 5ff6994 commit 4e944b7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/items/server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ function Items.Metadata(inv, item, metadata, count)
if not metadata.ammo and item.ammoname then metadata.ammo = 0 end
if not metadata.components then metadata.components = {} end

if metadata.registered ~= false and metadata.ammo then
if metadata.registered ~= false and (metadata.ammo or item.name == 'WEAPON_STUNGUN') then
metadata.registered = type(metadata.registered) == 'string' and metadata.registered or inv.player.name
metadata.serial = GenerateSerial(metadata.serial)
end
Expand Down

0 comments on commit 4e944b7

Please sign in to comment.