Assistance needed with Lua


MidrealmDM

Recommended Posts

I am needing to insert a bit of code into the prepared foods.lua in the core game scripts.

Spoiler

for k,recipe in pairs(foods) do
    AddCookerRecipe("portablecookpot", recipe)
end

 

In case it matters the preparedfoods.lua is as follows:

Spoiler

 

local foods=
{
    butterflymuffin =
    {

--[[ every crock pot recipe listed here, removed for sake of keeping the post short ]]

      },
}

for k,v in pairs(foods) do
    v.name = k
    v.weight = v.weight or 1
    v.priority = v.priority or 0
end

--[[ extra bit of code needs to be inserted here ]]

return foods

 

Does anyone know how to make this happen?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.