Advertisement
acool

Untitled

Aug 13th, 2023 (edited)
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.71 KB | None | 0 0
  1. --pastebin run AZxZBRNi
  2.  
  3. print("welcome to goober OS")
  4. print("setting up....")
  5.  
  6. print("do you have a modem(Y/N)")
  7. local modem = "NO MODEM"
  8. local event, key, is_held = os.pullEvent("key")
  9.  
  10. if key == (keys.getName(key) == Y or (keys.getName(key) == y then
  11.     peripheral.find("modem")
  12.     print("modem selected")
  13.  
  14. elseif (keys.getName(key) == N or (keys.getName(key) == n then
  15.     print("no modem selected")
  16. end
  17.  
  18. print("do you have a monitor?(Y/N)")
  19. local monitor = "NO MONITOR"
  20.  
  21. if (keys.getName(key) == Y or key (keys.getName(key) == y then
  22.     peripheral.find("monitor")
  23.     print("monitor found!")
  24.  
  25. elseif (keys.getName(key) == N or (keys.getName(key) == n then
  26.     print("no monitor selected")
  27. end
  28.  
  29.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement