Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct wTileMapBackup declared space #487

Merged
merged 2 commits into from
Jan 28, 2025
Merged

Conversation

Engezerstorung
Copy link
Contributor

wTileMapBackup isnt just used to backup the tilemap but also as a buffer for a screen view out of blocks during the drawing of the tilemap

i just changed the ds value but a new union with its own label could also be an idea
maybe also some more constants like in crystal, those values being used in LoadCurrentMapView

constants from crystal :
DEF METATILE_WIDTH EQU 4 ; tiles
DEF SCREEN_META_WIDTH EQU 6 ; metatiles
DEF SCREEN_META_HEIGHT EQU 5 ; metatiles
DEF SURROUNDING_WIDTH EQU SCREEN_META_WIDTH * METATILE_WIDTH ; tiles
DEF SURROUNDING_HEIGHT EQU SCREEN_META_HEIGHT * METATILE_WIDTH ; tiles
DEF MAP_CONNECTION_PADDING_WIDTH EQU 3 ; metatiles

ram/wram.asm Outdated Show resolved Hide resolved
Copy link
Member

@Rangi42 Rangi42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this update! I want to make some changes before merge, at least the town_map.asm usages of this RAM location.

wTileMapBackup isnt just used to backup the tilemap but also as a buffer for a screen view out of blocks during the drawing of the tilemap, define a new union reflecting that.
Add map gfx values in gfx_constants.asm.
Edit overworld.asm to replace hardcoded values with new constants.
@Rangi42 Rangi42 removed their assignment Jan 28, 2025
@Rangi42 Rangi42 self-requested a review January 28, 2025 17:06
@Rangi42 Rangi42 merged commit 96fc617 into pret:master Jan 28, 2025
1 check passed
github-actions bot pushed a commit that referenced this pull request Jan 28, 2025
@dannye
Copy link
Member

dannye commented Jan 28, 2025

Neat, thanks!

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.

3 participants