Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local m = peripheral.wrap("top")
- User = "Androthia"
- Pass = "apple55"
- local cPrint = function(text)
- local x2, y2 = term.getCursorPos()
- local x, y = term.getSize()
- term.setCursorPos(math.ceil((x / 2) - (text:len() / 2)), y2)
- print(text)
- end
- local Clear = function()
- term.clear()
- term.setCursorPos(1,6)
- end
- while true do
- Clear()
- cPrint("Welcome to the Farmcraft Management System")
- cPrint("==========================================")
- cPrint("Please Enter Username")
- term.setCursorPos(38,8)
- input1 = read()
- if input1 == User then
- cPrint("Please Enter Password")
- term.setCursorPos(38,9)
- input2 = read("*")
- if input2 == Pass then
- cPrint("Authenticating")
- term.setCursorPos(25,11)
- textutils.slowWrite("....", 1)
- Clear()
- textutils.tabulate(shell.run("gui"))
- break
- end
- end
- if input1 ~= User then
- cPrint("Access Denied")
- sleep(2)
- elseif input2 ~= Pass then
- cPrint("Access Denied")
- sleep(2)
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement