Skip to content

Instantly share code, notes, and snippets.

@Kramin42
Forked from anonymous/datboi
Last active June 7, 2016 04:15
Show Gist options
  • Save Kramin42/a6c9535e1998f7fd8874be4503480cb1 to your computer and use it in GitHub Desktop.
Save Kramin42/a6c9535e1998f7fd8874be4503480cb1 to your computer and use it in GitHub Desktop.
Ben and Cam's CC API
-- helper functions edited
function waitFuel(n)
n = n or 100
while turtle.getFuelLevel()<n do
while not turtle.refuel(1) do
turtle.select(turtle.getSelectedSlot()%16+1)
end
end
end
function forceForward(n)
n = n or 1
for i=1,n do
while not turtle.forward() do
turtle.dig()
os.sleep(0.25)
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment