Anonymous

Module:LevelUpTable/Data: Difference between revisions

From Melvor Idle
Add cooking data
(Add firemaking data)
(Add cooking data)
Line 161: Line 161:
return UnlockData.new(x.id, logs.name, Skills.getRecipeLevel(skillID, x), skillID)
return UnlockData.new(x.id, logs.name, Skills.getRecipeLevel(skillID, x), skillID)
end)
end)
end
function getCookingData(realm)
local skillID = 'Cooking'
local data = getDataSet(SkillData.Cooking.recipes, realm)
return Select(data, function(x)
local foodItem = Items.getItemByID(x.productID)
return UnlockData.new(foodItem.id, foodItem.name, Skills.getRecipeLevel(skillID, x), x.categoryID)
end)
end
end


Line 257: Line 267:


function p.test()
function p.test()
--local realmName = 'Abyssal Realm'
local realmName = 'Abyssal Realm'
local realm = Skills.getRealmFromName(realmName)
local realm = Skills.getRealmFromName(realmName)
Debug.log(getFiremakingData(realm))
Debug.log(getCookingData(realm))
end
end


p.UnlockData = UnlockData
p.UnlockData = UnlockData
return p
return p
2,875

edits