Skip to content

Instantly share code, notes, and snippets.

@croxis
Last active December 15, 2015 21:38
Show Gist options
  • Save croxis/5326758 to your computer and use it in GitHub Desktop.
Save croxis/5326758 to your computer and use it in GitHub Desktop.
mc2
--[[
computer_0 mission control
monitor_1 monitor
computer_2 force field generator
MISSION CONTROL LAUNCH WARNING
--]]
print("Starting mission control launch warning system")
modem = peripheral.wrap('right')
modem.open(1926)
while true do
_, side, freq, rfreq, message = os.pullEvent('modem_message')
if freq == 1926 then
if message == "launch-shield" then
redstone.setOutput("back", true)
end
if message == "disable-shield" then
redstone.setOutput("back", false)
end
end
end
print("End")
redstone.setOutput("back", false)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment