Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local component=require("component")
- local r=component.redstone
- local gpu=component.gpu
- local term=require("term")
- local component = require("component")
- local gpu = component.gpu
- local w, h = gpu.getResolution()
- gpu.fill(1, 1, w, h, " ")
- gpu.setForeground(0x000000)
- gpu.setBackground(0xFFFFFF)
- gpu.fill(1, 1, w/2, h/2, "X")
- gpu.copy(1, 1, w/2, h/2, w/2, h/2)
- local password="0419"
- local delay=5
- local side=5
- local wrong=false
- while true do
- term.clear()
- gpu.set(1,1,"Passwort eingeben")
- if wrong then
- gpu.set(1,1, "Passwort falsch")
- wrong=false
- end
- term.setCursor(1,2)
- local input=io.read()
- if input==password then
- r.setOutput(5, 15)
- os.sleep(50)
- r.setOutput(5,0)
- else
- wrong=false
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement