Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function UI(Str)
- term.clear()
- term.setCursorPos(14, 5)
- print("####################")
- term.setCursorPos(14, 6)
- print("# CONTROLE D'ACCES #")
- term.setCursorPos(14, 7)
- print(Str)
- term.setCursorPos(14, 8)
- print("####################")
- end
- while true do
- UI("# CODE NECESSAIRE #")
- term.setCursorPos(14, 10)
- print(">>")
- term.setCursorPos(16, 10)
- local input = read("*")
- if input == "machine" then
- UI("# PORTE OUVERTE #")
- redstone.setOutput("right", true)
- sleep(3)
- UI("# PORTE CLOSE #")
- redstone.setOutput("right", false)
- sleep(3)
- else
- if input == "gestion" then
- UI("# CODE GESTION #")
- term.setCursorPos(1, 1)
- term.clear()
- error("ouverture de la gestion")
- else
- UI("# CODE FAUX #")
- sleep(3)
- end
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement