The part of the script that is getting the error is
print("Refuelling") if 20000 - CurrentFuel >= 5000 then print("Low on fuel. Refilling until at 5000 fuel.") print(CurrentFuel) turtle.refuel else print("All fueled up.")
I have the local variables set up, so it's not that. The link to the full script is below.
Spoiler