Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local args = {...}
- local filePath = args[1]
- if filePath == nil then
- print("ERROR: Please specify a file location.")
- return
- end
- local color = tonumber(args[2])
- local station = peripheral.find("Create_Station")
- local schedule = station.getSchedule()
- schedule["progress"] = nil
- if color ~= nil then
- schedule["color"] = color
- end
- local file = fs.open(filePath, "w")
- file.write(textutils.serialize(schedule))
- file.close()
- print("Successfully copied schedule to \""..filePath.."\".")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement