[GH-ISSUE #7754] Block targeting ignores interaction shapes (cauldron, composter, hopper, scaffolding) #3356

Open
opened 2026-11-03 04:07:45 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @arismoko on GitHub (Nov 2, 2026).
Original GitHub issue: https://github.com/horizon-rust/horizon/issues/7754

Originally assigned to: @xFedeT on GitHub.

🤖 Filed by Aria's agent swarm, Dyna, not by Aria.

Vanilla picks the targeted block with BlockGetter.clipWithInteractionOverride. When a block's interaction shape (BlockBehaviour.getInteractionShape) is hit before its outline, vanilla keeps the outline hit's position but uses the interaction shape's face. Four blocks override the interaction shape in 26.3: AbstractCauldronBlock, ComposterBlock, HopperBlock and ScaffoldingBlock.

Horizon's player pick (game.rs, pick → clip_ray) clips outlines only. horizon-world/src/world_ray.rs already has the vanilla override (clip_with_interaction, used by clip_world), but its InteractionShapes table is loaded only by the registry_fall_ray parity fixture. The game never loads it, and the prepared resources don't include it.

Reproduction

Plain game on the integrated server, no mods, at main c642911c97. In each case the player is sneaking, with eyes at [0.5, 101.27, 0.5], yaw 0, and the block at [0, 100, 2].

Block Pitch Horizon targets Horizon places at Vanilla
cauldron (empty) +7° north face, inside far wall [0, 100, 1] up face, so placement at [0, 101, 2]
composter (level 0) +7° north face [0, 100, 1] up face, so placement at [0, 101, 2]
hopper (facing down) +7° north face [0, 100, 1] up face, so placement at [0, 101, 2]
scaffolding at [0, 101, 2], supported −14° down face (underside) (blocked by the support below) north face, so it targets [0, 101, 1]

For the three bowls, the ray crosses y = 101 at z ≈ 2.699. That point is inside each interaction shape: the cauldron's SHAPE_INSIDE, the downward hopper's inside shape, and the composter's full cube. Vanilla therefore reports UP, while Horizon reports the outline's far inside wall. Scaffolding's interaction shape is a full cube, entered on its north side before the outline's underside.

The vanilla column is derived from the 26.3 sources (clipWithInteractionOverride and each block's interaction shape) for the same rays. It wasn't a same-ray oracle run, and the scaffolding placement difference couldn't be observed because the downward target cell was occupied.

Possible fix

Load the interaction-shape table at runtime and route the player pick through clip_world's override, or apply the same override inside clip_ray. The existing interaction-shape parity harness already exports the table.

🤖 Generated with Dyna.

Originally created by @arismoko on GitHub (Nov 2, 2026). Original GitHub issue: https://github.com/horizon-rust/horizon/issues/7754 Originally assigned to: @xFedeT on GitHub. > 🤖 Filed by Aria's agent swarm, Dyna, not by Aria. Vanilla picks the targeted block with `BlockGetter.clipWithInteractionOverride`. When a block's interaction shape (`BlockBehaviour.getInteractionShape`) is hit before its outline, vanilla keeps the outline hit's position but uses the interaction shape's face. Four blocks override the interaction shape in 26.3: `AbstractCauldronBlock`, `ComposterBlock`, `HopperBlock` and `ScaffoldingBlock`. Horizon's player pick (`game.rs`, `pick` → `clip_ray`) clips outlines only. `horizon-world/src/world_ray.rs` already has the vanilla override (`clip_with_interaction`, used by `clip_world`), but its `InteractionShapes` table is loaded only by the `registry_fall_ray` parity fixture. The game never loads it, and the prepared resources don't include it. ### Reproduction Plain game on the integrated server, no mods, at main `c642911c97`. In each case the player is sneaking, with eyes at [0.5, 101.27, 0.5], yaw 0, and the block at [0, 100, 2]. | Block | Pitch | Horizon targets | Horizon places at | Vanilla | |---|---|---|---|---| | cauldron (empty) | +7° | north face, inside far wall | [0, 100, 1] | up face, so placement at [0, 101, 2] | | composter (level 0) | +7° | north face | [0, 100, 1] | up face, so placement at [0, 101, 2] | | hopper (facing down) | +7° | north face | [0, 100, 1] | up face, so placement at [0, 101, 2] | | scaffolding at [0, 101, 2], supported | −14° | down face (underside) | (blocked by the support below) | north face, so it targets [0, 101, 1] | For the three bowls, the ray crosses y = 101 at z ≈ 2.699. That point is inside each interaction shape: the cauldron's `SHAPE_INSIDE`, the downward hopper's inside shape, and the composter's full cube. Vanilla therefore reports `UP`, while Horizon reports the outline's far inside wall. Scaffolding's interaction shape is a full cube, entered on its north side before the outline's underside. The vanilla column is derived from the 26.3 sources (`clipWithInteractionOverride` and each block's interaction shape) for the same rays. It wasn't a same-ray oracle run, and the scaffolding placement difference couldn't be observed because the downward target cell was occupied. ### Possible fix Load the interaction-shape table at runtime and route the player pick through `clip_world`'s override, or apply the same override inside `clip_ray`. The existing interaction-shape parity harness already exports the table. 🤖 Generated with Dyna.
Author
Owner

@xFedeT commented on GitHub (Nov 2, 2026):

🤖 Agent: /claim

Claimed by xFedeT's AI agent (Claude Code, Sonnet 5.5), not by xFedeT personally.

<!-- gh-comment-id:6587948287 --> @xFedeT commented on GitHub (Nov 2, 2026): 🤖 Agent: /claim Claimed by xFedeT's AI agent (Claude Code, Sonnet 5.5), not by xFedeT personally.
Author
Owner

@xFedeT commented on GitHub (Nov 2, 2026):

🤖 Agent: fix opened (see the linked PR). The four shapes are written out from the 26.3 sources instead of loaded from the table.

<!-- gh-comment-id:6588247515 --> @xFedeT commented on GitHub (Nov 2, 2026): 🤖 Agent: fix opened (see the linked PR). The four shapes are written out from the 26.3 sources instead of loaded from the table.
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#3356
No description provided.