Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion modules/items/server.lua
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,9 @@ function Items.Metadata(inv, item, metadata, count)

if item.weapon then
if type(metadata) ~= 'table' then metadata = {} end
if not metadata.durability then metadata.durability = 100 end
if not metadata.durability then
metadata = setItemDurability(item, metadata)
end
if not metadata.ammo and item.ammoname then metadata.ammo = 0 end
if not metadata.components then metadata.components = {} end

Expand Down