Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local running = true
- --local eventm = event,arg,x,y = os.pullEvent("mouse_click")
- function clear(t)
- term.clear()
- term.setCursorPos(1,1)
- if t == nil then
- term.setCursorPos(19,4)
- term.setTextColor(8)
- write("Enter Password")
- term.setTextColor(1)
- term.setCursorPos(22,7)
- write("1 2 3")
- term.setCursorPos(22,9)
- write("4 5 6")
- term.setCursorPos(22,11)
- write("7 8 9")
- end
- end
- function marker()
- -- while true do
- event,arg,x,y = os.pullEvent("mouse_click")
- term.setCursorPos(x,y)
- term.setTextColor(4)
- write("*")
- sleep(1)
- clear()
- term.setTextColor(1)
- -- end
- end
- while running do
- clear()
- --marker()
- event,arg,x,y = os.pullEventRaw()
- if event == "mouse_click" and x == 28 and y == 7 then
- --marker()
- event,arg,x,y = os.pullEventRaw()
- if event == "mouse_click" and x == 25 and y == 9 then
- --marker()
- event,arg,x,y = os.pullEventRaw()
- if event == "mouse_click" and x == 28 and y == 11 then
- --marker()
- event,arg,x,y = os.pullEventRaw()
- if event == "mouse_click" and x == 28 and y == 9 then
- term.setCursorPos(18,14)
- term.setTextColor(32)
- write("Correct Password!")
- term.setTextColor(1)
- sleep(1)
- running = false
- end
- end
- end
- end
- end
- clear(1)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement