Skip to content

Commit f4311a7

Browse files
committed
postEvent in the place manager
1 parent 19f6d0d commit f4311a7

File tree

1 file changed

+9
-2
lines changed
  • common/src/main/kotlin/com/lambda/interaction/request/placing

1 file changed

+9
-2
lines changed

common/src/main/kotlin/com/lambda/interaction/request/placing/PlaceManager.kt

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,12 +132,19 @@ object PlaceManager : RequestHandler<PlaceRequest>(), PositionBlocking {
132132
val hotbarRequest = request.hotbarConfig.request(HotbarRequest(ctx.hotbarIndex))
133133
if (ctx.sneak && notSneaking) {
134134
shouldCrouch = true
135+
postEvent()
135136
return@listen
136137
}
137138
rotation?.let { rotation ->
138-
if (rotation !== ctx.rotation || !validRotation) return@listen
139+
if (rotation !== ctx.rotation || !validRotation) {
140+
postEvent()
141+
return@listen
142+
}
143+
}
144+
if (!hotbarRequest.done) {
145+
postEvent()
146+
return@listen
139147
}
140-
if (!hotbarRequest.done) return@listen
141148

142149
val actionResult = placeBlock(ctx, request, Hand.MAIN_HAND)
143150
if (!actionResult.isAccepted) {

0 commit comments

Comments
 (0)