Laine_prikol

LockSystem

May 1st, 2016
81
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. local term = require("term")
  2. local sides = require("sides")
  3. local note = require("note")
  4. local os = require("os")
  5.  
  6. local password = try
  7. term.clear()
  8. while true do
  9.   io.write("Enter password: ")
  10.   err, try = pcall(io.read)
  11.   -- Защита от особо умных которые хотят всё взломать
  12.   if not err then
  13.     print("No, no, no!")
  14.   elseif try == "os_start" then -- Вот и пароль меняется тут
  15.     os.execute("OS_start.lua")
  16.     term.clear()
  17.   else
  18.     -- NEt
  19.     print("Wrong password!")
  20.     note.play(50, 0.2)
  21.   end
  22. end
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.

×