Hello, Experts and Professionals alike!
I made a simple program that mines an array of blocks based on width, depth, and height.
To combat early turning due to gravel and sand, I created a loop as follows:
function safetycheck
while there is a block in front of you,
break it
wait 1 second
(this allows time for gravel and sand to fall, so the loop can repeat until the falling blocks are depleted)
end the while
function closed
However, waiting 1 second makes my mining sluggish
I was wondering if anybody knew the exact amount of ticks it took for gravel and sand to fall, so I could shorten my wait time in the loop to just 1 tick longer.
This would speed up the program execution immensely, I believe.
Please note: I went to "ask a pro" and searched "gravel" and "gravel ticks", and stopped browsing after 5 results pages and dozens of threads that I skimmed, with no results.
The official MC Wiki page for Gravel does not say either, and just short of deobfuscating the actual source code, I'm not sure what to do.
Thanks for the help,
~John
0
2 replies to this topic
#1
Posted 06 August 2015 - 04:20 AM
#2
Posted 06 August 2015 - 04:36 AM
You don't need to wait for the gravel / sand to fall, just continue to mine until the turtle is able to move
Don't worry about the turtle moving under a falling block, I don't think it can happen
EDIT: missed the () for turtle.forward
while not turtle.forward() do turtle.dig() end
Don't worry about the turtle moving under a falling block, I don't think it can happen
EDIT: missed the () for turtle.forward
Edited by HPWebcamAble, 07 August 2015 - 03:32 AM.
#3
Posted 07 August 2015 - 12:45 AM
Aah that makes much more sense. Very concise, I like it... or should I say I dig it? ha.
Thank you sir!
Thank you sir!
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users