Anonymous

Module:Items/UseTables: Difference between revisions

From Melvor Idle
m
Fix Summoning non-shard item cost quantity
(Update for v1.0.3)
m (Fix Summoning non-shard item cost quantity)
Line 456: Line 456:
end
end
local nonShardItem = Items.getItemByID(nonShardItemID)
local nonShardItem = Items.getItemByID(nonShardItemID)
local itemValue = math.max(item.sellsFor, 20)
local itemValue = math.max(nonShardItem.sellsFor, 20)
local nonShardQty = math.max(1, math.floor(recipeGPCost / itemValue))
local nonShardQty = math.max(1, math.floor(recipeGPCost / itemValue))
local recipeCosts = Shared.clone(recipe.itemCosts)
local recipeCosts = Shared.clone(recipe.itemCosts)