Replace magic numbers with TILE_WIDTH (#1056)

* Replace magic numbers with TILE_WIDTH

* Address more instances
This commit is contained in:
Idain
2023-07-26 20:50:16 -04:00
committed by GitHub
parent 1d64befdb7
commit 94df3c5aa3
17 changed files with 62 additions and 62 deletions

View File

@@ -955,10 +955,10 @@ Intro_PlacePlayerSprite:
.sprites
db 4
; y pxl, x pxl, tile offset
db 9 * 8 + 4, 9 * 8, 0
db 9 * 8 + 4, 10 * 8, 1
db 10 * 8 + 4, 9 * 8, 2
db 10 * 8 + 4, 10 * 8, 3
db 9 * TILE_WIDTH + 4, 9 * TILE_WIDTH, 0
db 9 * TILE_WIDTH + 4, 10 * TILE_WIDTH, 1
db 10 * TILE_WIDTH + 4, 9 * TILE_WIDTH, 2
db 10 * TILE_WIDTH + 4, 10 * TILE_WIDTH, 3
const_def

View File

@@ -375,7 +375,7 @@ NamingScreenJoypadLoop:
depixel 10, 3
call NamingScreen_IsTargetBox
jr nz, .got_cursor_position
ld d, 8 * 8
ld d, 8 * TILE_WIDTH
.got_cursor_position
ld a, SPRITE_ANIM_INDEX_NAMING_SCREEN_CURSOR
call InitSpriteAnimStruct