You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[1.21.1-0.8.1a] Colony Integrator getWorkOrderResources(), 'needed' property returns a nil value #851
When using the Colony Integrator the 'needed' property when called from getWorkOrderResources returns a value of 'nil' instead of the expected value. All of the other properties seem to report back the correct values as expected.
local colony = peripheral.find("colony_integrator")
local work = colony.getWorkOrders()
for i, val in pairs(work) do
textutils.pagedPrint("--------------------------")
textutils.pagedPrint(val.displayName.." Level: "..val.level.." to "..val.targetLevel)
textutils.pagedPrint(val.isClaimed)
local idstr = val.id
local id = tonumber(idstr)
local orders = colony.getWorkOrderResources(id)
for i, val2 in pairs(orders) do
textutils.pagedPrint(val2.displayName)
textutils.pagedPrint(val2.status)
textutils.pagedPrint(val2.available.."/"..tostring(val2.needed))
textutils.pagedPrint(val2.delivering)
end
end
Steps to reproduce
Obtain Advanced Colony Pocket Computer.
Use the code above to print the 'needed' value from getWorkOrderResources (or write your own).
Ensure a build job is currently underway in the colony.
Run code and the 'needed' property will return as 'nil' instead of the expected value.
Multiplayer?
Yes
Version
1.21.1-0.8.1a (Latest 1.21.1)
Minecraft, Forge and maybe other related mods versions
Activity