Skip to content

Commit

Permalink
fix: block Breaking Cooldown in Creative
Browse files Browse the repository at this point in the history
  • Loading branch information
sakura-ryoko committed Aug 24, 2024
1 parent b09a66b commit c94fe7e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,8 @@ private void handleBreakingRestriction1(BlockPos pos, Direction side, CallbackIn
@Inject(method = "updateBlockBreakingProgress", at = @At("HEAD"), cancellable = true) // MCP: onPlayerDamageBlock
private void handleBreakingRestriction2(BlockPos pos, Direction side, CallbackInfoReturnable<Boolean> cir)
{
if (Configs.Disable.DISABLE_BLOCK_BREAK_COOLDOWN.getBooleanValue())
if (Configs.Disable.DISABLE_BLOCK_BREAK_COOLDOWN.getBooleanValue() &&
this.client.player.isCreative() == false)
{
this.blockBreakingCooldown = 0;
}
Expand Down

0 comments on commit c94fe7e

Please sign in to comment.