Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local chest=peripheral.wrap("back")
- local count=0
- local list={}
- --print(chest.listMethods())
- for c= 1,27 do
- if chest.getStackInSlot(c) then
- for i,v in pairs(chest.getStackInSlot(c)) do
- list[i]=v
- end
- if list["display_name"]=="Iron Ingot" then
- count=count+tonumber(list["qty"])
- print(list["qty"])
- end
- end
- end
- print("payment detected: "..count)
Add Comment
Please, Sign In to add comment