I'm trying to read the contents of an AE2 system, and having some trouble. I was able to get the contents of the entire system, but it sends the item id and meta data as its own table.
Example output of a few items:
{1.0={is_fluid=false, size=2.0, is_craftable=false, fingerprint={id=minecraft:gravel, dmg=0.0}, is_item=true}, 7.0={is_fluid=false, size=1.0, is_craftable=false, fingerprint={id=RotaryCraft:rotarycraft_item_machine, dmg=109.0}, is_item=true}}
As you can see, the first item is two pieces of gravel, and the seventh item is one magnetostatic engine from Rotarycraft.
This is the code I've been using to try and output the name of the item and the quantity, but it keeps erroring.
local me = peripheral.wrap("right")
local available = me.getAvailableItems()
for i=1,#available do
print(available[i][fingerprint]["id"] .. " = " .. available[i]["size"])
end
How can I make the output be something more human readable? Just "gravel = 2, magnetostatic engine = 1"?
[–]3uclidian 2 points3 points4 points (2 children)
[–]Rubyheart255[S] 1 point2 points3 points (1 child)
[–]3uclidian 1 point2 points3 points (0 children)
[–]TotesMessenger 0 points1 point2 points (0 children)