17,101
edits
(getFarmingPlotTable: Fix missing item costs & plot order) |
(getRecipeRequirements: Support 'requirements' property of recipes. Also replaces the 'shopItemPurchased' property) |
||
Line 6: | Line 6: | ||
local GameData = require('Module:GameData') | local GameData = require('Module:GameData') | ||
local SkillData = GameData.skillData | local SkillData = GameData.skillData | ||
local Common = require('Module:Common') | |||
local Common = require('Module:Common') | local Common = require('Module:Common') | ||
local Items = require('Module:Items') | local Items = require('Module:Items') | ||
local Icons = require('Module:Icons') | local Icons = require('Module:Icons') | ||
local Skills = require('Module:Skills') | local Skills = require('Module:Skills') | ||
local ItemSourceTables = require('Module:Items/SourceTables') | local ItemSourceTables = require('Module:Items/SourceTables') | ||
Line 21: | Line 21: | ||
table.insert(reqText, Shared.formatnum(recipe.totalMasteryRequired) .. ' ' .. Icons.Icon({skillName, type='skill', notext=true}) .. ' ' .. Icons.Icon({'Mastery'})) | table.insert(reqText, Shared.formatnum(recipe.totalMasteryRequired) .. ' ' .. Icons.Icon({skillName, type='skill', notext=true}) .. ' ' .. Icons.Icon({'Mastery'})) | ||
end | end | ||
if recipe. | if type(recipe.requirements) == 'table' then | ||
local | local reqs = Common.getRequirementString(recipe.requirements) | ||
if | if reqs ~= nil then | ||
table.insert(reqText, | table.insert(reqText, reqs) | ||
end | end | ||
end | end |