17,097
edits
(Use printError function) |
(_getItemUseTable: Correct base experience for Farming) |
||
Line 458: | Line 458: | ||
local product = Items.getItemByID(recipe.productId) | local product = Items.getItemByID(recipe.productId) | ||
local mat = {{id = recipe.seedCost.id, quantity = recipe.seedCost.quantity}} | local mat = {{id = recipe.seedCost.id, quantity = recipe.seedCost.quantity}} | ||
local rowReq = recipe.level | local rowReq = recipe.level | ||
local category = GameData.getEntityByID(SkillData.Farming.categories, recipe.categoryID) | local category = GameData.getEntityByID(SkillData.Farming.categories, recipe.categoryID) | ||
local qty = 5 * category.harvestMultiplier | local qty = 5 * category.harvestMultiplier | ||
local xp = recipe.baseExperience * ((category.scaleXPWithQuantity and qty) or 1) | |||
table.insert(useArray, {item = {id = product.id, name = product.name}, qty = qty, mats = mat, skill = 'Farming', req = rowReq, xp = xp}) | table.insert(useArray, {item = {id = product.id, name = product.name}, qty = qty, mats = mat, skill = 'Farming', req = rowReq, xp = xp}) | ||
end | end |