Advertisement
osmarks

Held Item Monitor

Mar 16th, 2019
186
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.24 KB | None | 0 0
  1. local md = peripheral.wrap "back"
  2. local en = ...
  3.  
  4. while true do
  5.     local hi = md.getMetaByName(en).heldItem
  6.     if hi then
  7.         local me = hi.getMetadata()
  8.         print(me.name, me.count, me.displayName)
  9.     else
  10.         print "[EMPTY]"
  11.     end
  12.     sleep(1)
  13. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement