mirror of
https://gitlab.com/xCrystal/pokecrystal-board.git
synced 2024-11-16 11:27:33 -08:00
Fix magic numbers in Celebi event code
This commit is contained in:
parent
5d94f1c7b4
commit
5fb672b220
@ -132,7 +132,7 @@ UpdateCelebiPosition:
|
||||
ld hl, SPRITEANIMSTRUCT_YCOORD
|
||||
add hl, bc
|
||||
ld a, [hl]
|
||||
cp 8 * 10 + 2
|
||||
cp 10 * TILE_WIDTH + 2
|
||||
jp nc, .FreezeCelebiPosition
|
||||
ld hl, SPRITEANIMSTRUCT_YCOORD
|
||||
add hl, bc
|
||||
@ -159,9 +159,9 @@ UpdateCelebiPosition:
|
||||
ld hl, SPRITEANIMSTRUCT_XCOORD
|
||||
add hl, bc
|
||||
add [hl]
|
||||
cp 8 * 11 + 4
|
||||
cp 11 * TILE_WIDTH + 4
|
||||
jr nc, .ShiftY
|
||||
cp 8 * 8 + 4
|
||||
cp 8 * TILE_WIDTH + 4
|
||||
jr nc, .ReinitSpriteAnimFrame
|
||||
.ShiftY:
|
||||
pop af
|
||||
@ -171,7 +171,7 @@ UpdateCelebiPosition:
|
||||
ld hl, SPRITEANIMSTRUCT_XCOORD
|
||||
add hl, bc
|
||||
add [hl]
|
||||
cp 8 * 10
|
||||
cp 10 * TILE_WIDTH
|
||||
jr c, .float_up
|
||||
jr .float_down
|
||||
|
||||
@ -179,7 +179,7 @@ UpdateCelebiPosition:
|
||||
ld hl, SPRITEANIMSTRUCT_XCOORD
|
||||
add hl, bc
|
||||
add [hl]
|
||||
cp 8 * 10
|
||||
cp 10 * TILE_WIDTH
|
||||
jr nc, .float_up
|
||||
.float_down
|
||||
ld hl, SPRITEANIMSTRUCT_YCOORD
|
||||
@ -200,9 +200,9 @@ UpdateCelebiPosition:
|
||||
ld hl, SPRITEANIMSTRUCT_XCOORD
|
||||
add hl, bc
|
||||
add [hl]
|
||||
cp 8 * 10
|
||||
cp 10 * TILE_WIDTH
|
||||
jr c, .left
|
||||
cp -(8 * 3 + 2)
|
||||
cp -(3 * TILE_WIDTH + 2)
|
||||
jr nc, .left
|
||||
ld hl, SPRITEANIMSTRUCT_FRAMESET_ID
|
||||
add hl, bc
|
||||
|
Loading…
Reference in New Issue
Block a user