Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- os.pullEvent = os.pullEventRaw
- local configTable = {Name, Password, "1.1.2"}
- function save(table,name)
- local file = fs.open(name,"w")
- file.write(textutils.serialize(table))
- file.close()
- end
- function writeName()
- Name = read()
- term.clear()
- term.setCursorPos(1, 3)
- term.write("Your computer is now named:")
- term.setCursorPos(1, 4)
- term.write(Name)
- os.sleep(1)
- table.insert(configTable, 1, Name)
- end
- function writePass()
- Password = read()
- term.clear()
- term.setCursorPos(1, 3)
- term.write("Your Password is now:")
- term.setCursorPos(1, 4)
- term.write(Password)
- os.sleep(1)
- table.insert(configTable, 2, Password)
- end
- term.clear()
- term.setCursorPos(1, 1)
- term.write("Welcome to the SETUP program.")
- term.setCursorPos(1, 2)
- term.write("Please Write your Desired computer Name.")
- term.setCursorPos(1, 3)
- writeName()
- term.clear()
- term.setCursorPos(1, 2)
- term.write("Please Write your Desired Password.")
- term.setCursorPos(1, 3)
- writePass()
- os.sleep(2)
- os.setComputerLabel("ROBCO UNIVERSAL TERMINAL")
- fs.makeDir("/R_Files")
- fs.makeDir("/R_Files/Documents")
- fs.makeDir("/R_Files/Programs")
- save(configTable, "RobcOS_ticket")
- os.reboot()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement