shithub: pokecrystal

Download patch

ref: e140e88b7b38f5c70aa6ddcf826f88bcafee4ea3
parent: ed0a0f71591dd802d6491d57a52040a360cfb406
author: Rangi <remy.oukaour+rangi42@gmail.com>
date: Sun May 30 19:32:03 EDT 2021

Add more comments to tileset palette animation functions

--- a/engine/tilesets/tileset_anims.asm
+++ b/engine/tilesets/tileset_anims.asm
@@ -922,7 +922,7 @@
 	ret nz
 
 ; Ready for BGPD input
-	ld a, (1 << rBGPI_AUTO_INCREMENT) palette PAL_BG_WATER
+	ld a, (1 << rBGPI_AUTO_INCREMENT) palette PAL_BG_WATER color 0
 	ldh [rBGPI], a
 
 	ldh a, [rSVBK]
@@ -937,6 +937,8 @@
 	cp %100
 	jr z, .color2
 
+; Copy one color from hl to rBGPI via rBGPD
+
 ; color1
 	ld hl, wBGPals1 palette PAL_BG_WATER color 1
 	ld a, [hli]
@@ -987,7 +989,7 @@
 	ldh [rSVBK], a
 
 ; Ready for BGPD input
-	ld a, (1 << rBGPI_AUTO_INCREMENT) palette PAL_BG_YELLOW
+	ld a, (1 << rBGPI_AUTO_INCREMENT) palette PAL_BG_YELLOW color 0
 	ldh [rBGPI], a
 
 ; A cycle of 2 colors (0 2), updating every other vblank
@@ -994,6 +996,8 @@
 	ldh a, [hVBlankCounter]
 	and %10
 	jr nz, .color1
+
+; Copy one color from hl to rBGPI via rBGPD
 
 ; color0
 	ld hl, wBGPals1 palette PAL_BG_YELLOW color 0