Skip to content

Commit 7f78b68

Browse files
committed
only place shulkers on our y level until we can check where we can path to reliably
1 parent a9663e8 commit 7f78b68

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,12 @@ class PlaceContainer @Ta5kBuilder constructor(
6060
.simulate(player.eyePos)
6161
}
6262

63+
// ToDo: Check based on if we can move the player close enough rather than y level once the custom pathfinder is merged
6364
val succeeds = results.filterIsInstance<PlaceResult.Place>().filter {
64-
canBeOpened(startStack, it.blockPos, it.context.result.side)
65+
canBeOpened(startStack, it.blockPos, it.context.result.side) && it.blockPos.y == player.blockPos.y
6566
}
6667
val wrongStacks = results.filterIsInstance<BuildResult.WrongItemSelection>().filter {
67-
canBeOpened(startStack, it.blockPos, it.context.result.side)
68+
canBeOpened(startStack, it.blockPos, it.context.result.side) && it.blockPos.y == player.blockPos.y
6869
}
6970
(succeeds + wrongStacks).minOrNull()?.let { result ->
7071
build(

0 commit comments

Comments
 (0)