Advertisement
Guest User

Untitled

a guest
Mar 27th, 2015
246
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.54 KB | None | 0 0
  1. local component = require(component)
  2.  
  3. local listComponents = function()
  4.   local address = 0
  5.   local type = 0
  6.   for address, type in component.list() do
  7.     print(type .. " " .. address)
  8.     print("debug1")
  9.   end
  10.   print("debug2")
  11. end
  12.  
  13. local listMethods = function(address)
  14.   local address = component.get(address)
  15.   local proxy = component.proxy(address)
  16.   for i, v in pairs(proxy) do
  17.     print(i .. " " .. v)
  18.   end
  19. end
  20.  
  21. local main = function()
  22.   listComponents()
  23.   local input = io.read()
  24.   listmethods(input)
  25. end
  26.  
  27. main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement