We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e974e70 commit 6953949Copy full SHA for 6953949
lib/plugins/digging.js
@@ -24,6 +24,11 @@ function inject (bot) {
24
digFace = 'auto'
25
}
26
27
+ const waitTime = bot.digTime(block)
28
+ if (waitTime === Infinity) {
29
+ throw new Error(`dig time for ${block?.name ?? block} is Infinity`)
30
+ }
31
+
32
bot.targetDigFace = 1 // Default (top)
33
34
if (forceLook !== 'ignore') {
@@ -127,7 +132,6 @@ function inject (bot) {
127
132
location: block.position,
128
133
face: bot.targetDigFace // default face is 1 (top)
129
134
})
130
- const waitTime = bot.digTime(block)
131
135
waitTimeout = setTimeout(finishDigging, waitTime)
136
bot.targetDigBlock = block
137
bot.swingArm()
0 commit comments