diff options
| author | dannye <33dannye@gmail.com> | 2025-07-02 21:15:13 -0500 |
|---|---|---|
| committer | dannye <33dannye@gmail.com> | 2025-07-02 21:15:13 -0500 |
| commit | ca019eac8fd96559f4d4e712f0b53e95492e5dcb (patch) | |
| tree | 209a500e3bda6c2109e5acec60448e9e52f8c2af /ram | |
| parent | Use more ldpikacry (diff) | |
| parent | Require RGBDS 0.9.3 for its DMG palette specs (#513) (diff) | |
| download | pokeyellow-ca019eac8fd96559f4d4e712f0b53e95492e5dcb.tar.gz pokeyellow-ca019eac8fd96559f4d4e712f0b53e95492e5dcb.tar.xz pokeyellow-ca019eac8fd96559f4d4e712f0b53e95492e5dcb.zip | |
Merge branch 'master' of https://github.com/pret/pokered
Diffstat (limited to 'ram')
| -rw-r--r-- | ram/vram.asm | 4 | ||||
| -rw-r--r-- | ram/wram.asm | 28 |
2 files changed, 16 insertions, 16 deletions
diff --git a/ram/vram.asm b/ram/vram.asm index 04556410..fafb5d8e 100644 --- a/ram/vram.asm +++ b/ram/vram.asm @@ -5,8 +5,8 @@ UNION vChars0:: ds $80 tiles vChars1:: ds $80 tiles vChars2:: ds $80 tiles -vBGMap0:: ds BG_MAP_WIDTH * BG_MAP_HEIGHT -vBGMap1:: ds BG_MAP_WIDTH * BG_MAP_HEIGHT +vBGMap0:: ds TILEMAP_AREA +vBGMap1:: ds TILEMAP_AREA NEXTU ; battle/menu diff --git a/ram/wram.asm b/ram/wram.asm index 68a04fcb..7b03c846 100644 --- a/ram/wram.asm +++ b/ram/wram.asm @@ -149,7 +149,7 @@ SECTION "OAM Buffer", WRAM0 ; buffer for OAM data. Copied to OAM by DMA wShadowOAM:: ; wShadowOAMSprite00 - wShadowOAMSprite39 -FOR n, NUM_SPRITE_OAM_STRUCTS +FOR n, OAM_COUNT wShadowOAMSprite{02d:n}:: sprite_oam_struct wShadowOAMSprite{02d:n} ENDR wShadowOAMEnd:: @@ -158,13 +158,13 @@ wShadowOAMEnd:: SECTION "Tilemap", WRAM0 ; buffer for tiles that are visible on screen (20 columns by 18 rows) -wTileMap:: ds SCREEN_WIDTH * SCREEN_HEIGHT +wTileMap:: ds SCREEN_AREA ; This union spans 480 bytes. UNION ; buffer for temporarily saving and restoring current screen's tiles ; (e.g. if menus are drawn on top) -wTileMapBackup:: ds SCREEN_WIDTH * SCREEN_HEIGHT +wTileMapBackup:: ds SCREEN_AREA NEXTU ; buffer for the blocks surrounding the player (6 columns by 5 rows of 4x4-tile blocks) @@ -174,7 +174,7 @@ NEXTU ; buffer for temporarily saving and restoring shadow OAM wShadowOAMBackup:: ; wShadowOAMBackupSprite00 - wShadowOAMBackupSprite39 -FOR n, NUM_SPRITE_OAM_STRUCTS +FOR n, OAM_COUNT wShadowOAMBackupSprite{02d:n}:: sprite_oam_struct wShadowOAMBackupSprite{02d:n} ENDR wShadowOAMBackupEnd:: @@ -489,7 +489,7 @@ wNPCMovementScriptBank:: db ; This union spans 180 bytes. UNION -wVermilionDockTileMapBuffer:: ds 5 * BG_MAP_WIDTH + SCREEN_WIDTH +wVermilionDockTileMapBuffer:: ds 5 * TILEMAP_WIDTH + SCREEN_WIDTH wVermilionDockTileMapBufferEnd:: NEXTU @@ -1095,7 +1095,7 @@ UNION wSerialOtherGameboyRandomNumberListBlock:: ds $11 NEXTU ; second buffer for temporarily saving and restoring current screen's tiles (e.g. if menus are drawn on top) -wTileMapBackup2:: ds SCREEN_WIDTH * SCREEN_HEIGHT +wTileMapBackup2:: ds SCREEN_AREA ENDU ; This union spans 30 bytes. @@ -1990,11 +1990,11 @@ wObjectDataPointerTemp:: dw ; the tile shown outside the boundaries of the map wMapBackgroundTile:: db -; number of warps in current map (up to 32) +; number of warps in current map (up to MAX_WARP_EVENTS) wNumberOfWarps:: db ; current map warp entries -wWarpEntries:: ds 32 * 4 ; Y, X, warp ID, map ID +wWarpEntries:: ds MAX_WARP_EVENTS * 4 ; Y, X, warp ID, map ID ; if $ff, the player's coordinates are not updated when entering the map wDestinationWarpID:: db @@ -2078,13 +2078,13 @@ wd49b:: db ds 19 -; number of signs in the current map (up to 16) +; number of signs in the current map (up to MAX_BG_EVENTS) wNumSigns:: db -wSignCoords:: ds 16 * 2 ; Y, X -wSignTextIDs:: ds 16 +wSignCoords:: ds MAX_BG_EVENTS * 2 ; Y, X +wSignTextIDs:: ds MAX_BG_EVENTS -; number of sprites on the current map (up to 16) +; number of sprites on the current map (up to MAX_OBJECT_EVENTS) wNumSprites:: db ; these two variables track the X and Y offset in blocks from the last special warp used @@ -2092,8 +2092,8 @@ wNumSprites:: db wYOffsetSinceLastSpecialWarp:: db wXOffsetSinceLastSpecialWarp:: db -wMapSpriteData:: ds 16 * 2 ; movement byte 2, text ID -wMapSpriteExtraData:: ds 16 * 2 ; trainer class/item ID, trainer set ID +wMapSpriteData:: ds MAX_OBJECT_EVENTS * 2 ; movement byte 2, text ID +wMapSpriteExtraData:: ds MAX_OBJECT_EVENTS * 2 ; trainer class/item ID, trainer set ID ; map height in 2x2 meta-tiles wCurrentMapHeight2:: db |
