I may be incorrect in my thinking, but this led me to believe that calling ".get_inventory(defines.inventory.character_main)" on say, a steel-chest, would give me an actual nil result. Instead, with serpent.block(), I get this:Return values
:: LuaInventory?
The inventory or nil if none with the given index was found.
Code: Select all
{
{
__self = "userdata"
},
{
__self = 0
},
{
__self = 0
},
[...]
-- repeats 44 more times
[...]
{
__self = 0
},
__self = 0
}
Edit: Ok, sorry, it seems that no matter what I give it, it returns with the chest's inventory? I'm confused now.