Repository navigation
Fix comparator block entities, mode toggling and loading - #260
Open
Paul1365972 wants to merge 4 commits into
Open
Paul1365972 wants to merge 4 commits into
Paul1365972 wants to merge 4 commits into
Conversation
Paul1365972
force-pushed
the
fix/comparator-state
branch
2 times, most recently
from
September 12, 2026 15:53
f5487b6 to
a118bdf
Compare
Contributor
Author
|
Dropped the extra reset before the final save, |
Paul1365972
force-pushed
the
fix/comparator-state
branch
from
September 30, 2026 15:23
a118bdf to
70f119a
Compare
Contributor
Author
|
Since the last push:
|
benburk
added a commit
to benburk/MCHPRS
that referenced
this pull request
Oct 29, 2026
As MCHPR#260 does in flush: a comparator's block entity holds the strength the backend computed, so it can be read back from the world.
benburk
added a commit
to benburk/MCHPRS
that referenced
this pull request
Nov 2, 2026
As MCHPR#260 does in flush: a comparator's block entity holds the strength the backend computed, so it can be read back from the world.
Paul1365972
marked this pull request as draft
November 2, 2026 22:08
Paul1365972
force-pushed
the
fix/comparator-state
branch
from
November 16, 2026 18:56
70f119a to
dd52f08
Compare
Paul1365972
marked this pull request as ready for review
November 16, 2026 18:57
Paul1365972
force-pushed
the
fix/comparator-state
branch
from
November 16, 2026 22:25
dd52f08 to
756d2a4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Redpiler's
flushwrote comparator blocks but never their block entities, onlyresetdid.Saves and copies taken while Redpiler was running got stale
OutputSignalvalues.With
--io-onlyit was worse,resetwrote live output strengths next to block states frozen at compile time, so a comparator could end up unpowered with an output of 15.flushnow writes the block entity together with each comparator block it writes, andresetflushes all changed nodes, including internal ones under--io-only, before clearing its state.Saves and copies need no extra flush since every tick path already flushes right after ticking.
Also fixed:
OutputSignalpanicked. It now loads with an output of 0. Values outside 0..=15 are clamped because Redpiler indexes arrays by signal strength without bounds checks.CountandSlotof container items.Known limitations:
--io-only, internal nodes are still only written on reset, so saves and copies during a run see their compile-time state.--io-only --optimize, comparators pruned as orphans are never written and keep their compile-time block state and block entity after reset.