File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed
common/src/main/kotlin/com/lambda/task Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -54,7 +54,7 @@ abstract class Task<Result> : Nameable {
5454 open var timeout: Int = Int .MAX_VALUE
5555 open var tries: Int = 0
5656 open var repeats: Int = 0
57- open val cooldown: Int = TaskFlow .taskCooldown
57+ open var cooldown: Int = TaskFlow .taskCooldown
5858 open val onStart: SafeContext .(Task <Result >) -> Unit = {}
5959 open val onSuccess: SafeContext .(Task <Result >, Result ) -> Unit = { _, _ -> }
6060 open val onRetry: SafeContext .(Task <Result >) -> Unit = {}
Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ class BreakBlock @Ta5kBuilder constructor(
3737 val blockPos: BlockPos get() = ctx.result.blockPos
3838 private var beginState: BlockState ? = null
3939 val SafeContext .state: BlockState get() = blockPos.blockState(world)
40- override val cooldown
40+ override var cooldown = Int . MAX_VALUE
4141 get() = maxOf(TaskFlow .build.breakCoolDown, TaskFlow .taskCooldown)
4242 private var drop: ItemEntity ? = null
4343
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ class PlaceBlock @Ta5kBuilder constructor(
1919 private val waitForConfirmation : Boolean ,
2020) : Task<Unit>() {
2121 private var beginState: BlockState ? = null
22- override val cooldown
22+ override var cooldown = Int . MAX_VALUE
2323 get() = maxOf(TaskFlow .build.placeCooldown, TaskFlow .taskCooldown)
2424 override var timeout = 20
2525 private var placed = false
You can’t perform that action at this time.
0 commit comments