Editing Module:ProfessionList
Jump to navigation
Jump to search
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 156: | Line 156: | ||
local fullRecipe = search.main(item.product) |
local fullRecipe = search.main(item.product) |
||
-- overwrite any parameters from the original recipe with their counterparts from the full recipe |
-- overwrite any parameters from the original recipe with their counterparts from the full recipe |
||
-- |
-- when product is nil, no data is overwritten |
||
-- first need to nil the xp, kp, and duration, since if they are nil in the fullRecipe they must stay nil |
|||
item.xp = nil |
|||
item.kp = nil |
|||
item.duration = nil |
|||
for key,value in pairs(fullRecipe) do |
for key,value in pairs(fullRecipe) do |
||
item[key] = value |
item[key] = value |