Markers classify by what they are, not where they draw - #80
Merged
Conversation
MarkerBase (and with it every spawner and atmos-fix marker) draws at Overdoors (+10), the same depth band as doors. The layer filter bucketed purely by draw depth and only tested marker-ness inside the 0..+7 band, so every marker landed in the Doors bucket: the Doors toggle hid them all, and the Markers / Atmos Markers toggles hit nothing. Classify markers before the depth bands. The existing tests all passed depth 0, which is exactly how this slipped through; the new ones pin the real depth.
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.
About
Field report: the Atmos Markers layer toggle did nothing, and atmos markers hid with the Doors toggle instead.
Root cause:
MarkerBase(and with it every spawner and atmos-fix marker in the corpus) draws atOverdoors(+10), the same depth band as doors. The layer filter bucketed purely by draw depth and only checked marker-ness inside the 0..+7 band, so every marker fell through to the Doors bucket. Doors toggle hid all markers; Markers and Atmos Markers toggles hit nothing.The fix moves the marker checks in front of the depth bands: markers are a semantic category, not a depth band, so they answer to their own toggles at any draw depth. Actual doors still follow the Doors toggle.
So worth flagging: the existing tests all exercised markers at depth 0, where the old code happened to work. That is exactly how this shipped broken. The new tests pin the real depth (+10).
Testing
npx vitest run src/rendering/__tests__/markerLayer.test.ts- 14 passing, 5 new cases covering markers at +10 (marker toggles work, Doors toggle leaves them alone, real doors still hide).Checklist