Skip to content

Preserve Crystal source VRAM tile identities in imported atlases - #336

Open
Roxas2712 wants to merge 1 commit into
UNDERdecoded:mainfrom
Roxas2712:codex/upstream-gen2-vram-layout
Open

Roxas2712 wants to merge 1 commit into
UNDERdecoded:mainfrom
Roxas2712:codex/upstream-gen2-vram-layout

Conversation

@Roxas2712

@Roxas2712 Roxas2712 commented Oct 27, 2026 •

Copy link
Copy Markdown

Crystal tileset extraction currently compacts bank 1 from source tile addresses $80–$df to $60–$bf. This changes the public identity of those tiles even though the compact atlas itself can still render.

Preserve the source VRAM bank boundary in the atlas, metatile references and decoded palette map. Add a Gen2 import marker revision to rebuild older generated assets. Single-bank and explicit attribute-bank formats keep their existing decoder. Saves and opaque mod storage are not rewritten.

Validation on this upstream-based branch: 577 synthetic extraction/layout/palette/cache-invalidation checks plus 21 adjacent Gen1 palette checks passed. No ROM, mod or derived artwork is included. Integration against a fresh private Crystal import in the development fork also matched every one of the 2,048 Johto metatile references against a Gen1 reference; that is not a full visual-parity or final-package claim. Existing persistent mod-mesh caches still need migration validation.

Original contributions by Roxas2712 are offered under LICENSE-ROXAS2712.md, including the specific integration permission for Cedric / UNDERdecoded with visible credit. Existing authors’ rights and licenses remain in force.

Composed upgrade follow-up

A separate current-fork 5dd7f527 run cloned an owned pre-fix QA profile with generated ROM data and opaque mod caches, then used the normal importer and unchanged external mod. The VRAM revision updated without a blanket mod-cache reset. Natural START/options, starter acquisition and a Route29 wild command menu passed; FULL scenery drew all four near maps with zero guard fallback. Of 1,448 fresh generated Lua/PNG files, 1,447 matched byte-for-byte; the remaining maps file matched in a strict parsed-value/shared-table comparison covering 75,504 nodes. The original old profile, source mod and ROM remained unchanged. This is composed fork/internal-framebuffer evidence, not independent-branch GPU, OS-window, all-world/settings or final package acceptance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant