Advanced Peripherals

Advanced Peripherals

29M Downloads

Colony Integrator no longer returns item names in getWorkOrderResources()

SolarNightx opened this issue ยท 2 comments

commented

Describe

In previous versions the getWorkOrderResources() and getBuilderResources() functions would return a table including the name and display name of every item being requested making it easy to request items from an rs bridge. Now the functions only return the display name of each item which (as far as Im aware) cant be used to fetch items from an rs bridge.

Steps to reproduce

Run this code

local integrator = peripheral.wrap("top") -- Colony Integrator
local bridge = peripheral.wrap("right") -- ME Bridge

function dump(o)
if type(o) == 'table' then
local s = '{ \n'
for k,v in pairs(o) do
if type(k) ~= 'number' then k = '"'..k..'"' end
s = s .. '['..k..'] = ' .. dump(v) .. ',\n'
end
return s .. '} '
else
return tostring(o)
end
end

for k,v in ipairs(integrator.getWorkOrders()) do
if v.type == "WorkOrderBuilding" then
print("Resources:", dump(integrator.getWorkOrderResources(v.id))) -- Prints the
end
end

Multiplayer?

Yes

Version

1.19.2-0.7.22b (Latest 1.19)

Minecraft, Forge and maybe other related mods versions

Forge 43.1.55 Minecraft 1.19.2

Screenshots or Videos

https://cdn.discordapp.com/attachments/1061029279456047216/1061029369562279964/problem.png

Crashlog/log

No response

commented

will be fixed with the 1.19.3 port
Thank you for the report

commented

Reopen until release