Advertisement
Guest User

Code

a guest
Oct 10th, 2015
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.63 KB | None | 0 0
  1. c = tonumber(...)
  2.  
  3. maxfalse = 5
  4.  
  5. ffalse=0
  6. if c == 0 then
  7.   print("NO! add Arguments")
  8.   os.reboot()
  9. end
  10. while true do
  11.  
  12.   term.clear()
  13.   term.setCursorPos(1,1)
  14.   print("enter Password        (",maxfalse-ffalse," Versuche Verbleibend)")
  15.   x=tonumber(read())
  16.  
  17.   if c == x then
  18.     rs.setOutput("left",true)
  19.     sleep(5)
  20.     rs.setOutput("left",false)
  21.   else
  22.     ffalse=ffalse+1
  23.     if ffalse==maxfalse then
  24.       term.clear()
  25.       term.setCursorPos(1,1)
  26.       print("Now I only want you gone!")
  27.       rs.setOutput("bottom",true)
  28.       sleep(15)
  29.       rs.setOutput("bottom",false)
  30.       ffalse=0
  31.     end
  32.   end
  33.  
  34. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement