ref: 6962d843a35727ca28d6713bf40db18308810c0b
parent: 01618d3cc46af567eea6c72ec88a2488002ca2b0
author: Rangi <[email protected]>
date: Sun Aug 11 14:48:26 EDT 2019
Store Magnet Train tilemaps in their own files
--- a/engine/events/magnet_train.asm
+++ b/engine/events/magnet_train.asm
@@ -175,19 +175,19 @@
hlbgcoord 0, 6
ld de, MagnetTrainTilemap
- ld c, 20
+ ld c, SCREEN_WIDTH
call .FillLine
hlbgcoord 0, 7
- ld de, MagnetTrainTilemap + 20
- ld c, 20
+ ld de, MagnetTrainTilemap + SCREEN_WIDTH
+ ld c, SCREEN_WIDTH
call .FillLine
hlbgcoord 0, 8
- ld de, MagnetTrainTilemap + (20 * 2)
- ld c, 20
+ ld de, MagnetTrainTilemap + (SCREEN_WIDTH * 2)
+ ld c, SCREEN_WIDTH
call .FillLine
hlbgcoord 0, 9
- ld de, MagnetTrainTilemap + (20 * 3)
- ld c, 20
+ ld de, MagnetTrainTilemap + (SCREEN_WIDTH * 3)
+ ld c, SCREEN_WIDTH
call .FillLine
ret
@@ -222,25 +222,8 @@
ret
MagnetTrainBGTiles:
-; Alternating tiles for each line of the Magnet Train tilemap.
- db $4c, $4d ; bush
- db $5c, $5d ; bush
- db $4c, $4d ; bush
- db $5c, $5d ; bush
- db $08, $08 ; fence
- db $18, $18 ; fence
- db $1f, $1f ; track
- db $31, $31 ; track
- db $11, $11 ; track
- db $11, $11 ; track
- db $0d, $0d ; track
- db $31, $31 ; track
- db $04, $04 ; fence
- db $18, $18 ; fence
- db $4c, $4d ; bush
- db $5c, $5d ; bush
- db $4c, $4d ; bush
- db $5c, $5d ; bush
+; 2x18 tilemap, repeated in vertical strips for the background.
+INCBIN "gfx/overworld/magnet_train_bg.tilemap"
MagnetTrain_InitLYOverrides:
ld hl, wLYOverrides
@@ -451,7 +434,5 @@
ret
MagnetTrainTilemap:
- db $1f, $05, $06, $0a, $0a, $0a, $09, $0a, $0a, $0a, $0a, $0a, $0a, $09, $0a, $0a, $0a, $0b, $0c, $1f
- db $14, $15, $16, $1a, $1a, $1a, $19, $1a, $1a, $1a, $1a, $1a, $1a, $19, $1a, $1a, $1a, $1b, $1c, $1d
- db $24, $25, $26, $27, $07, $2f, $29, $28, $28, $28, $28, $28, $28, $29, $07, $2f, $2a, $2b, $2c, $2d
- db $20, $1f, $2e, $1f, $17, $00, $2e, $1f, $1f, $1f, $1f, $1f, $1f, $2e, $17, $00, $1f, $2e, $1f, $0f
+; 20x4 tilemap
+INCBIN "gfx/overworld/magnet_train_fg.tilemap"
--- /dev/null
+++ b/gfx/overworld/magnet_train_bg.tilemap
@@ -1,0 +1,1 @@
+LM\]LM\]11 11LM\]LM\]
\ No newline at end of file
binary files /dev/null b/gfx/overworld/magnet_train_fg.tilemap differ