creeloper27

porta lock

Jun 20th, 2016
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.84 KB | None | 0 0
  1. -- ciao
  2.  
  3. pass = "unlock"
  4. debug = "debug"
  5. passd = "deb"
  6. latoaccesso = "back"
  7. latomorte = "bottom"
  8.  
  9. -- utilizzare monitor
  10.  
  11. print "bentornato"
  12. sleep(0.5)
  13. print "per favore inserisci la password d'accesso"
  14. sleep(0.5)
  15. write "password: "
  16.  
  17.  
  18. input = read()
  19.  
  20.  
  21. if pass == input then
  22.     print "system unlocked for 6 sec."
  23.     redstone.setOutput(latoaccesso,true)
  24.     sleep(6)
  25.     redstone.setOutput(latoaccesso,false)
  26.     os.reboot()
  27. elseif debug == input then
  28.     write "password for debugging: "
  29.     sleep(1)
  30.     input = read()
  31.         if passd == input() then
  32.         print "debugging mod activate"
  33.         sleep(1)
  34.         print "breaking"
  35.         end
  36. else
  37.     print "acces denied"
  38.     sleep(1)
  39.     print "muori ha hah ah ah"
  40.     print "sCeMo ChI lEgGe"
  41.     -- trappola con segnale di redstone
  42.     redstone.setOutput(latomorte,true)
  43.     sleep(2)
  44.     redstone.setOutput(latomorte,false)
  45.     os.reboot()
  46. end
Advertisement
Add Comment
Please, Sign In to add comment