Advertisement
Guest User

sdaw

a guest
Jun 25th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. os.pullEvent = os.pullEventRaw
  2. local side = "back"
  3. local password = "1"
  4. local vypnout = "2"
  5. while true do
  6. term.clear()
  7. term.setCursorPos(1,1)
  8. write("Co chcete udelat se svetly? ")
  9. print("-------------------")
  10. print("1) Zapnout")
  11. print("2) Vypnout")
  12. print("Napiste cislo, bez zavorky napr. 1")
  13. local input = read("")
  14. if input == password then
  15. term.clear()
  16. term.setCursorPos(1,1)
  17. print("Zapinam svetla!")
  18. print("Prosim vypnete svetla, az budete koncit.)
  19. rs.setOutput(side,true)
  20. else
  21. print("Vypinam svetla!")
  22. end
  23. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement