Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local url = "https://github.com/bartek18887/ComputerCraft-FlappyBird/raw/main/main.lua"
- local fileName = "flappybird.lua"
- -- Download the script
- local function download(url, fileName)
- if http then
- local response = http.get(url)
- if response then
- local file = fs.open(fileName, "w")
- file.write(response.readAll())
- file.close()
- print("Downloaded " .. fileName)
- else
- print("Failed to download " .. url)
- end
- else
- print("HTTP not enabled")
- end
- end
- -- Download and run the script
- download(url, fileName)
- shell.run(fileName)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement