Advertisement
Guest User

startup

a guest
Oct 25th, 2014
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.86 KB | None | 0 0
  1. local function login()
  2.     while true do
  3.     term.clear()
  4.     term.setCursorPos(1,1)
  5.     term.setTextColor(colors.green)
  6.     print("Please enter your PIN.")
  7.     input = read("*")
  8.       if input == "3285" then
  9.        print("Account Accessed.")
  10.        withdraw()
  11.       else
  12.        print("Wrong PIN. Locked out for 5 minutes.")
  13.       sleep(300)
  14.       end
  15.     end
  16. end
  17.  
  18. local function withdraw()
  19.     print("32 or 64")
  20.     input = read()
  21.     if input == "32" then
  22.     turtle.turnLeft()
  23.     turtle.turnLeft()
  24.     turtle.suck(32)
  25.     turtle.turnRight()
  26.     turtle.turnRight()
  27.        turtle.drop(32)
  28.     end
  29.     if input == "64" then
  30.     turtle.turnLeft()
  31.     turtle.turnLeft()
  32.     turtle.suck(64)
  33.     turtle.turnRight()
  34.     turtle.turnRight()
  35.        turtle.drop(64)
  36.     end
  37. end  
  38. -------------
  39. ----START----
  40. -------------
  41.  
  42. term.clear()
  43. login()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement