Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local args = {...}
- if #args ~= 1 then
- print("Exemplo de uso: pinfo <namePeripheral>")
- return
- end
- print("arg: "..args[1])
- local item = { peripheral.find(args[1]) }
- if #item == 0 then
- print("Não foi encontrado nenhum periférico com este nome")
- -- return
- end
- for key, value in pairs(item) do
- print(key.." - "..type(value))
- end
- -- print("item: "..item[1].getName())
- for key, value in pairs(peripheral.getMethods(args[1])) do
- print(key.." - "..value)
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement