Resetting turtles fuel levels.

  • The FTB Forum is now read-only, and is here as an archive. To participate in our community discussions, please join our Discord! https://ftb.team/discord

voidreality

New Member
Jul 29, 2019
117
0
0
I have a turtle that I WANT to remove all fuel from. The turtle has a label, but I want to test some refueling code and it will take forever to remove the current fuel levels from the turtle by moving it around. I tried clearing the label and replacing the turtle, but this didn't work. Any way to do this?
 

Eyamaz

New Member
Jul 29, 2019
2,373
0
0
Not that I know of. Easier to make a new turtle. I normally test complex lua script in creative. If it works well I keep a text editor open and type it all there to keep a copy I can drop directly into the jar so I don't have to retype it every new world.
 

Ughzug

New Member
Jul 29, 2019
80
2
1
label clear
works for me.

option 2 make a new turtle
option 3 make an ultimate charging station and park your turtle team there over night and never worry about fueling turtles again?
 

voidreality

New Member
Jul 29, 2019
117
0
0
Thanks for the comments. I was mostly just curious if I was overlooking some easy command. The turtle running out of fuel really isn't an issue for me. It's more a "feature" if I decide to release the script. The refueling stuff is really easy, but I have never done it with an AE interface and just wanted to double check the turtle would interact with the interfaces inventory correctly (which it does :))

option 2 make a new turtle

Then I'm stuck with a bunch of useless directories in my computers folder. This is what I seemed to be forced to do though if I want to test from no fuel :( What I ended up doing is just setting a refuel variable to something higher than was in the turtle.

Code:
fuelLevel = turtle.getFuelLevel()
fuelCheck =  fuelLevel + 1
if fuelCheck > fuelLevel then
  refuelMe()
end

This simulates no fuel and I could test my code.