Open
Conversation
Rename generic wd-prefixed WRAM labels to descriptive names across the AI, duel, card UI, OW movement, sprite animation, audio, and SFX subsystems.
There was a problem hiding this comment.
Pull request overview
Renames a large set of previously generic wd* WRAM labels to more descriptive symbols across core engine subsystems (AI, overworld, UI/menus, sprite/palette animation, credits, and audio), improving readability and maintainability of the assembly codebase.
Changes:
- Replaced many
wd*WRAM references with descriptivew*labels in engine/home code paths (AI, OW scrolling/movement, sprite/palette animation, menus). - Updated credits and deck/check-menu related state variables to named WRAM labels.
- Renamed SFX/music engine WRAM fields (channel masks, per-channel state, backup buffers) and adjusted SRAM mapping names for renamed WRAM fields.
Reviewed changes
Copilot reviewed 29 out of 29 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| src/home/unsorted.asm | Updates OW tileset/animated tile and palette animation WRAM references to named labels. |
| src/engine/play_area_menu.asm | Uses named WRAM flag for screen reinit behavior. |
| src/engine/glossary.asm | Uses named WRAM flag for glossary reinit behavior. |
| src/engine/credits_commands.asm | Renames credits scroll state bytes to wCreditsScroll* labels. |
| src/engine/bank4b.asm | Renames OW tilemap/tileset loading and sprite anim scratch variables. |
| src/engine/bank13.asm | Renames AI tracking/temp variables used in attack repetition and portrait logic. |
| src/engine/bank12.asm | Renames AI counters/temps used in turn logic and targeting decisions. |
| src/engine/bank0e.asm | Renames AI scratch variables used across multiple AI routines. |
| src/engine/bank0c.asm | Renames GR Island scroll configuration WRAM usage. |
| src/engine/bank0a.asm | Renames AI targeting temps and deck screen text pointer variable. |
| src/engine/bank09.asm | Renames duel coin-toss animation WRAM fields. |
| src/engine/bank08.asm | Renames an AI scratch byte used during bench scanning/selection logic. |
| src/engine/bank07.asm | Renames palette fade state and multiple duel animation/screen shake WRAM fields. |
| src/engine/bank06.asm | Renames naming screen cursor-row WRAM state. |
| src/engine/bank05.asm | Renames several AI evaluation flags/counters used in retreat/attack logic. |
| src/engine/bank04.asm | Renames OW/palette animation state and loaded BG map size references. |
| src/engine/bank03.asm | Renames save/warp and OW-object motion scratch variables. |
| src/engine/bank02.asm | Renames check-menu cursor navigation flags and deck/card-list UI flags. |
| src/data/save.asm | Updates WRAM↔SRAM mapper entries to renamed WRAM symbols. |
| src/audio/sfx2.asm | Renames SFX2 engine WRAM state (channel mask, pointers, per-channel fields). |
| src/audio/sfx1.asm | Renames SFX1 engine WRAM state (channel mask, pointers, per-channel fields). |
| src/audio/music7.asm | Renames music engine WRAM fields and backup/restore buffers for channel state. |
| src/audio/music6.asm | Same as music7: updates music engine WRAM names and backup/restore buffers. |
| src/audio/music5.asm | Same as music7: updates music engine WRAM names and backup/restore buffers. |
| src/audio/music4.asm | Same as music7: updates music engine WRAM names and backup/restore buffers. |
| src/audio/music3.asm | Same as music7: updates music engine WRAM names and backup/restore buffers. |
Comments suppressed due to low confidence (1)
src/engine/bank08.asm:393
- wAIEnergyTransMode is used here as a temporary “current minimum HP” value for comparisons (cp b / update when smaller). Since WRAM d082 has multiple aliases and this usage is not an Energy Trans mode, consider switching these references to a more fitting alias (e.g., wAITempHPRecoverAmount) or adding a generic temp-byte alias for d082 to avoid misleading naming.
ld a, [wAIEnergyTransMode]
inc b
cp b
jr c, .asm_20ab0
call Func_20be6
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Author
|
@copilot apply changes based on the comments in this thread |
papasmurph0
commented
Mar 30, 2026
Author
papasmurph0
left a comment
There was a problem hiding this comment.
i've been slaving away for a while.... got many more change to get touched up to present.
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.
Rename generic wd-prefixed WRAM labels to descriptive names across the AI, duel, card UI, OW movement, sprite animation, audio, and SFX subsystems.