Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- --Reactor Controller Installer
- print("Reactor Controller Installation\n")
- local apidir, link = "/reactor", "YfV1CAHb"
- if fs.exists("/disk/m1") ~= true then
- print("M1cr0API not found, Download now? (http_api must be enabled)")
- if string.lower(read()) == "yes" then
- print("Downloading...")
- shell.run("pastebin", "get", link, "/disk/m1")
- else error("Please put m1cr0api in /disk/m1") end
- end
- print("Select a Program (1 or 2):\n")
- print("1. Reactor Controller")
- print("2. RC RAT")
- local choice = tonumber(read())
- print("Please Wait, Floppy will eject momentarily...")
- if choice == 1 then
- if fs.exists("/startup") then fs.delete("/startup") end
- fs.copy("/disk/controller", "/startup")
- if fs.exists(apidir) ~= true then fs.makeDir(apidir) end
- if fs.exists(apidir.."/m1") then fs.delete(apidir.."/m1") end
- fs.copy("/disk/m1", apidir.."/m1")
- elseif choice == 2 then
- if fs.exists("/startup") then fs.delete("/startup") end
- fs.copy("/disk/rat", "/startup")
- if fs.exists("/m1") then fs.delete("/m1") end
- fs.copy("/disk/m1", "/m1")
- else error("Invalid Choice, please type 1 or 2") end
- if not shell.run(apidir.."/m1") then shell.run("/m1") end
- disk.eject(getperipheral("drive"))
- os.reboot()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement