Skip to content

Commit 5776f0d

Browse files
committed
reset the breaking values
1 parent 1347530 commit 5776f0d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

common/src/main/kotlin/com/lambda/task/tasks/BuildTask.kt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ class BuildTask @Ta5kBuilder constructor(
8989
private val instantBreaks = mutableSetOf<BreakContext>()
9090

9191
var breaking = false
92-
var breakingTicks= 0
92+
var breakingTicks = 0
9393
var soundsCooldown = 0.0f
9494

9595
private var placements = 0
@@ -382,14 +382,16 @@ class BuildTask @Ta5kBuilder constructor(
382382
BuildConfig.BreakConfirmationMode.AwaitThenBreak -> pendingInteractions.add(ctx)
383383
}
384384
currentInteraction = null
385+
breaking = false
386+
breakingTicks = 0
385387
}
386388

387389
private fun SafeContext.breakBlock(ctx: BreakContext): Boolean {
388390
if (player.isBlockBreakingRestricted(world, ctx.expectedPos, interaction.currentGameMode)) return false
389391

390392
if (HotbarManager.mainHandStack?.item?.canMine(ctx.checkedState, world, ctx.expectedPos, player) == false)
391393
return false
392-
val block = ctx.checkedState.block;
394+
val block = ctx.checkedState.block
393395
if (block is OperatorBlock && !player.isCreativeLevelTwoOp) return false
394396
if (ctx.checkedState.isAir) return false
395397

0 commit comments

Comments
 (0)