Advertisement
Guest User

startup

a guest
Jun 27th, 2016
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.93 KB | None | 0 0
  1. --   Unhackable Password Door v1.0 by zsmate13   --
  2. -- You can change the username and password and  --
  3. -- the redstone output side (in line 5, 28, 53)  --
  4. username = "yourname" -- Change the value between the strings --
  5. password = "yourpassword" -- Change the value between the strings --
  6. while true do
  7. redstone.setOutput("back",false)
  8. term.clear()
  9. term.setCursorPos(1,1)
  10. term.setTextColor(colors.orange)
  11. write(" Login:")
  12. write("                    ")
  13. term.setTextColor(colors.green)
  14. write("Unhackable Password Door")
  15. term.setCursorPos(41,2)
  16. print("by zsmate13")
  17. term.setTextColor(colors.gray)
  18. term.setCursorPos(31,3)
  19. print("build: 27062016  v1.0")
  20. term.setCursorPos(31,4)
  21. print("pastebin.com/3mkeUzby")
  22. term.setCursorPos(1,3)
  23. term.setTextColor(colors.lightBlue)
  24. write("Username: ")
  25. term.setTextColor(colors.white)
  26. input1 = read()
  27. term.setTextColor(colors.lightBlue)
  28. write("Password: ")
  29. term.setTextColor(colors.white)
  30. input2 = read("*")
  31. if input1 == username and input2 == password then
  32. redstone.setOutput("back",true)
  33. term.setTextColor(colors.lime)
  34. print("")
  35. write("Login succesful! Opening doors")
  36. sleep(1)
  37. write(".")
  38. sleep(1)
  39. write(".")
  40. sleep(1)
  41. write(".  ")
  42. sleep(1)
  43. term.setTextColor(colors.red)
  44. print("")
  45. print("Closing doors in:")
  46. term.setTextColor(colors.yellow)
  47. print("3")
  48. sleep(1)
  49. term.setTextColor(colors.orange)
  50. print("2")
  51. sleep(1)
  52. term.setTextColor(colors.red)
  53. print("1")
  54. sleep(1)
  55. print("")
  56. print("Doors closed")
  57. redstone.setOutput("back",false)
  58. sleep(1)
  59. term.setTextColor(colors.yellow)
  60. print("")
  61. write("Rebooting")
  62. sleep(1)
  63. write(".")
  64. sleep(1)
  65. write(".")
  66. sleep(1)
  67. write(".")
  68. sleep(1)
  69. os.reboot()
  70. else
  71. term.setTextColor(colors.red)
  72. print("")
  73. print("Incorrect username or password please try again later!")
  74. sleep(2)
  75. term.setTextColor(colors.yellow)
  76. print("")
  77. write("Rebooting")
  78. sleep(1)
  79. write(".")
  80. sleep(1)
  81. write(".")
  82. sleep(1)
  83. write(".")
  84. sleep(1)
  85. write(".")
  86. os.reboot()
  87. end
  88. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement