[PR #7364] [MERGED] port map: updateNeighborsAtExceptFromFacing is update_neighbors_at_except_oriented #7552

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

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/7364
Author: @MSedgeMC
Created: 11/2/2026
Status: ✅ Merged
Merged: 11/2/2026
Merged by: @ludovic111

Base: main ← Head: chore/mapgap-classes-07


📝 Commits (1)

  • 30b37d8 port map: updateNeighborsAtExceptFromFacing is update_neighbors_at_except_oriented

📊 Changes

1 file changed (+1 additions, -1 deletions)

View changed files

📝 tools/port_map/classes-07.tsv (+1 -1)

📄 Description

tools/port_map/classes-07.tsv row 183 named a fn that does not exist: gaps --kind map reports no fn crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except. The neighbour updater has Sim::update_neighbors_at and Sim::update_neighbors_at_oriented (no side skipped) and Sim::update_neighbors_at_except_oriented, which is the one that skips a facing — the cell was one suffix short.

row was now
183 CollectingNeighborUpdater.updateNeighborsAtExceptFromFacing port crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except port crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except_oriented
  • Sim::update_neighbors_at_except_oriented(pos, block, skip, orientation) pushes the Multi update with skip: Some(skip) and starts its index on the second direction when the skipped side is the first in the update order — the same method as vanilla's updateNeighborsAtExceptFromFacing(pos, block, skipDirection), which has no orientation parameter of its own. Horizon threads the orientation through every neighbour update (update_neighbors_at_oriented, neighbor_changed_at_oriented, neighbor_changed_full_oriented), and the callers here pass the one they hold — redstone.rs:571, redstone.rs:829 and interact.rs:511.
  • The note under the cell now says that, in place of an empty cell.

Map-check:

$ PORT_LEDGER_OUT=/tmp/led-mapgap python3 tools/port_ledger.py map-check tools/port_map/classes-07.tsv
189 rows, no problems.

Proven: update_neighbors_at_except_oriented is defined at update.rs:528 and builds the Multi update with skip: Some(...), with the index starting past the skipped direction when it comes first; the three call sites above reach it; and the neighbouring rows of this table (addAndRun, neighborChanged, runUpdates, shapeUpdate) already cite Sim fns in the same file the same way.

Not proven: that no caller needs a plain update_neighbors_at_except — the citation names the fn that answers vanilla, and if a caller ever has no orientation it can pass None; nothing in the tree does. Tick parity for the redstone and interaction callers is not claimed here.


🔄 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/7364 **Author:** [@MSedgeMC](https://github.com/MSedgeMC) **Created:** 11/2/2026 **Status:** ✅ Merged **Merged:** 11/2/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `chore/mapgap-classes-07` --- ### 📝 Commits (1) - [`30b37d8`](https://github.com/horizon-rust/horizon/commit/30b37d87480c138b151b925b09a6bf1e4ed73c15) port map: updateNeighborsAtExceptFromFacing is update_neighbors_at_except_oriented ### 📊 Changes **1 file changed** (+1 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `tools/port_map/classes-07.tsv` (+1 -1) </details> ### 📄 Description `tools/port_map/classes-07.tsv` row 183 named a fn that does not exist: `gaps --kind map` reports `no fn crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except`. The neighbour updater has `Sim::update_neighbors_at` and `Sim::update_neighbors_at_oriented` (no side skipped) and `Sim::update_neighbors_at_except_oriented`, which is the one that skips a facing — the cell was one suffix short. | row | was | now | | --- | --- | --- | | 183 `CollectingNeighborUpdater.updateNeighborsAtExceptFromFacing` | `port crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except` | `port crates/horizon-world/src/level/update.rs::Sim::update_neighbors_at_except_oriented` | - `Sim::update_neighbors_at_except_oriented(pos, block, skip, orientation)` pushes the `Multi` update with `skip: Some(skip)` and starts its index on the second direction when the skipped side is the first in the update order — the same method as vanilla's `updateNeighborsAtExceptFromFacing(pos, block, skipDirection)`, which has no orientation parameter of its own. Horizon threads the orientation through every neighbour update (`update_neighbors_at_oriented`, `neighbor_changed_at_oriented`, `neighbor_changed_full_oriented`), and the callers here pass the one they hold — `redstone.rs:571`, `redstone.rs:829` and `interact.rs:511`. - The note under the cell now says that, in place of an empty cell. Map-check: ``` $ PORT_LEDGER_OUT=/tmp/led-mapgap python3 tools/port_ledger.py map-check tools/port_map/classes-07.tsv 189 rows, no problems. ``` **Proven:** `update_neighbors_at_except_oriented` is defined at update.rs:528 and builds the `Multi` update with `skip: Some(...)`, with the index starting past the skipped direction when it comes first; the three call sites above reach it; and the neighbouring rows of this table (`addAndRun`, `neighborChanged`, `runUpdates`, `shapeUpdate`) already cite `Sim` fns in the same file the same way. **Not proven:** that no caller needs a plain `update_neighbors_at_except` — the citation names the fn that answers vanilla, and if a caller ever has no orientation it can pass `None`; nothing in the tree does. Tick parity for the redstone and interaction callers is not claimed here. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 07:19: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#7552
No description provided.