Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
- Code: Select all
local meta = minetest.env:get_meta(pos)
local inv = meta:get_inventory()
for i=1,4 do
local item_stack=inv:get_stack("items", i)
local item_table=item_stack:to_table()
if item_table[name] == itemname then
This returns me that item_table is nil and i can't understrand why.
Can anyone help me?