Skip to content

Instantly share code, notes, and snippets.

@Nathan22211
Last active May 24, 2026 12:31
Show Gist options
  • Select an option

  • Save Nathan22211/aeb08c4b255db64b213563bdbd76b5f4 to your computer and use it in GitHub Desktop.

Select an option

Save Nathan22211/aeb08c4b255db64b213563bdbd76b5f4 to your computer and use it in GitHub Desktop.
CC: Tweaked script for toggling factory
local relayA = peripheral.wrap("redstone_relay_0")
local biofuel_relay_state = false
while True do
print("enter machine to toggle")
local arg1 = read()
if arg1 == "biofuel" then
if biofuel_relay_state == false then
relayA.setOutput("back", true)
biofuel_relay_state = true
else
relayA.setOutput("back", false)
biofuel_relay_state = false
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment