-
-
Save croxis/5326572 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--[[ | |
computer_0 mission control | |
monitor_1 monitor | |
computer_2 force field generator | |
MISSION CONTROL | |
--]] | |
--[[monitor = peripheral.wrap('left') | |
monitor.callRemote("monitor_1", "clear") | |
monitor.callRemote("monitor_1", "setTextScale", 5) | |
monitor.callRemote("monitor_1", "write", "Test")--]] | |
monitor = peripheral.wrap('monitor_1') | |
monitor.clear() | |
monitor.setTextScale(5) | |
monitor.setCursorPos(1,2) | |
monitor.write("test") | |
width, height = monitor.getSize() | |
modem = peripheral.wrap('left') | |
function printScreen(message) | |
monitor.clear() | |
monitor.setTextScale(5) | |
monitor.setCursorPos(width/2-2,2) | |
monitor.write(message) | |
end | |
seconds = -30 | |
while seconds <= 15 do | |
printScreen("T " .. tostring(seconds)) | |
if seconds == -14 then | |
modem.transmit(1926, 1, 'launch-shield') | |
end | |
seconds = seconds + 1 | |
os.sleep(1) | |
end | |
modem.transmit(1926, 1, 'disable-shield') | |
printScreen("Launch completed") | |
--[[while true do: | |
poll for start signal | |
begin countdown at 30 seconds | |
fire forcefield and siren signal at 15 seconds | |
modem.transmit(1926,1,'launch-shield') | |
disable systems at + 15 seconds | |
modem.transmit(1926,1,'disable-shield') | |
--]] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment