[PR #2197] [MERGED] Chests with a block or a sitting cat on top no longer open #4095

Closed
opened 2026-11-03 04:14:39 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/2197
Author: @kacpherek
Created: 10/26/2026
Status: ✅ Merged
Merged: 10/26/2026
Merged by: @ludovic111

Base: main ← Head: fix/chest-blocked-above


📝 Commits (1)

  • 05fd9c3 Chests with a block or a sitting cat on top no longer open

📊 Changes

2 files changed (+53 additions, -0 deletions)

View changed files

📝 crates/horizon-client/src/game.rs (+4 -0)
📝 crates/horizon-client/src/game/storage.rs (+49 -0)

📄 Description

What and why

A chest with a solid block right above it still opened. Reproduced in game: place a chest, put stone on top, right-click the chest, and the menu opens. In vanilla nothing happens.

Now a chest, trapped chest or ender chest opens no menu when it is blocked. Opening a blocked chest also gives no open_chest stat and does not anger piglins, as in vanilla. This runs in the shared menu opener, so players on a server or LAN host are covered too.

  • Chest and trapped chest: blocked by a redstone conductor above, or by a sitting cat on top. For a double chest, either half being blocked is enough.
  • Ender chest: blocked only by a redstone conductor above (no cat check).
  • Hoppers and comparators keep ignoring the block above, as before.

Vanilla reference

  • ChestBlock.getMenuProvider calls combine(state, level, pos, false), which uses ChestBlock.isChestBlockedAt (isBlockedChestByBlock or isCatSittingOnChest).
  • DoubleBlockCombiner.combineWithNeigbour returns no menu when this half or the other half is blocked.
  • ChestBlock.useWithoutItem still returns SUCCESS when there is no menu provider.
  • EnderChestBlock.useWithoutItem returns SUCCESS early when the block above isRedstoneConductor.

Self-check

cargo check -p horizon-client passes.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/2197 **Author:** [@kacpherek](https://github.com/kacpherek) **Created:** 10/26/2026 **Status:** ✅ Merged **Merged:** 10/26/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `fix/chest-blocked-above` --- ### 📝 Commits (1) - [`05fd9c3`](https://github.com/horizon-rust/horizon/commit/05fd9c3795ab85b63cc1ab0a700e7d63cbf09f4e) Chests with a block or a sitting cat on top no longer open ### 📊 Changes **2 files changed** (+53 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-client/src/game.rs` (+4 -0) 📝 `crates/horizon-client/src/game/storage.rs` (+49 -0) </details> ### 📄 Description ## What and why A chest with a solid block right above it still opened. Reproduced in game: place a chest, put stone on top, right-click the chest, and the menu opens. In vanilla nothing happens. Now a chest, trapped chest or ender chest opens no menu when it is blocked. Opening a blocked chest also gives no `open_chest` stat and does not anger piglins, as in vanilla. This runs in the shared menu opener, so players on a server or LAN host are covered too. - Chest and trapped chest: blocked by a redstone conductor above, or by a sitting cat on top. For a double chest, either half being blocked is enough. - Ender chest: blocked only by a redstone conductor above (no cat check). - Hoppers and comparators keep ignoring the block above, as before. ## Vanilla reference - `ChestBlock.getMenuProvider` calls `combine(state, level, pos, false)`, which uses `ChestBlock.isChestBlockedAt` (`isBlockedChestByBlock` or `isCatSittingOnChest`). - `DoubleBlockCombiner.combineWithNeigbour` returns no menu when this half or the other half is blocked. - `ChestBlock.useWithoutItem` still returns `SUCCESS` when there is no menu provider. - `EnderChestBlock.useWithoutItem` returns `SUCCESS` early when the block above `isRedstoneConductor`. ## Self-check `cargo check -p horizon-client` passes. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:14:39 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#4095
No description provided.