Advertisement
Guest User

startup

a guest
Oct 20th, 2014
156
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.04 KB | None | 0 0
  1. error = "Mot de passe incorrect"
  2. facade = "bottom"
  3. aserror = false
  4.  
  5. term.setBackgroundColor(colors.green)
  6.  
  7. write("Username: ")
  8. username = read()
  9. write("Mot de passe: ")
  10. mdp = read()
  11.  
  12. if username == "Coca" then
  13.  
  14.   if mdp == "swag" then
  15.  
  16.     print("ok")
  17.  
  18.   else
  19.     term.setBackgroundColor(colors.red)
  20.     print(error)
  21.     aserror = true
  22.   end
  23.  
  24.  
  25. elseif username == "AzorKill" then
  26.  
  27.   if mdp == "eole" then
  28.    
  29.     print("ok")
  30.  
  31.   else
  32.     term.setBacgroundColor(colors.red)
  33.     print(error)
  34.     aserror = true
  35.   end
  36.  
  37. elseif username == "Gauthier" then
  38.  
  39.   if mdp == "nrgy" then
  40.     print("ok")
  41.    
  42.   else
  43.     term.setBackgroundColor(colors.red)
  44.     print(error)
  45.     aserror = true
  46.  
  47.   end
  48.  
  49. elseif username == "Predator" then
  50.  
  51.   if mdp == "Gulli" then
  52.  
  53.     print("ok")
  54.   else
  55.   term.setBackgroundColor(colors.red)
  56.   print(error)
  57.   aserror = true
  58.  end
  59. end
  60.  
  61. if aserror then
  62.   sleep(5)
  63.   os.shutdown()
  64. end
  65.  
  66. rs.setOutput(facade, true)
  67. sleep(5)
  68. rs.setOutput(facade, false)
  69.  
  70. os.shutdown()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement