aboutsummaryrefslogtreecommitdiffstats
path: root/engine/movie
diff options
context:
space:
mode:
authorRangi <35663410+Rangi42@users.noreply.github.com>2020-07-19 23:04:16 -0400
committerGitHub <noreply@github.com>2020-07-19 23:04:16 -0400
commit0177688ad4d923c4970009fa87df48605bb43ed6 (patch)
tree4c44fbb1813e78eb00f7c1690d2c23099a49113b /engine/movie
parentMerge pull request #277 from Rangi42/master (diff)
parentMissingno's Pokédex weight is two bytes like the rest (diff)
downloadpokeyellow-0177688ad4d923c4970009fa87df48605bb43ed6.tar.gz
pokeyellow-0177688ad4d923c4970009fa87df48605bb43ed6.tar.xz
pokeyellow-0177688ad4d923c4970009fa87df48605bb43ed6.zip
Merge pull request #279 from Rangi42/master
Identify sprite and battle animation data
Diffstat (limited to 'engine/movie')
-rwxr-xr-xengine/movie/gamefreak.asm74
-rwxr-xr-xengine/movie/hall_of_fame.asm2
-rwxr-xr-xengine/movie/intro.asm16
-rwxr-xr-xengine/movie/trade.asm52
4 files changed, 71 insertions, 73 deletions
diff --git a/engine/movie/gamefreak.asm b/engine/movie/gamefreak.asm
index 1463eb4f..1f837443 100755
--- a/engine/movie/gamefreak.asm
+++ b/engine/movie/gamefreak.asm
@@ -146,7 +146,7 @@ AnimateShootingStar:
ret
SmallStarsOAM:
- db $00,$00,$A2,$90
+ dbsprite 0, 0, 0, 0, $A2, OAM_BEHIND_BG | OAM_OBP1
SmallStarsOAMEnd:
SmallStarsWaveCoordsPointerTable:
@@ -161,28 +161,28 @@ SmallStarsWaveCoordsPointerTable:
; These arrays contain the Y and X coordinates of each OAM entry.
SmallStarsWave1Coords:
- db $68,$30
- db $68,$40
- db $68,$58
- db $68,$78
+ db $68, $30
+ db $68, $40
+ db $68, $58
+ db $68, $78
SmallStarsWave2Coords:
- db $68,$38
- db $68,$48
- db $68,$60
- db $68,$70
+ db $68, $38
+ db $68, $48
+ db $68, $60
+ db $68, $70
SmallStarsWave3Coords:
- db $68,$34
- db $68,$4C
- db $68,$54
- db $68,$64
+ db $68, $34
+ db $68, $4C
+ db $68, $54
+ db $68, $64
SmallStarsWave4Coords:
- db $68,$3C
- db $68,$5C
- db $68,$6C
- db $68,$74
+ db $68, $3C
+ db $68, $5C
+ db $68, $6C
+ db $68, $74
SmallStarsEmptyWave:
db $FF
@@ -213,29 +213,29 @@ MoveDownSmallStars:
ret
GameFreakLogoOAMData:
- db $48,$50,$8D,$00
- db $48,$58,$8E,$00
- db $50,$50,$8F,$00
- db $50,$58,$90,$00
- db $58,$50,$91,$00
- db $58,$58,$92,$00
- db $60,$30,$80,$00
- db $60,$38,$81,$00
- db $60,$40,$82,$00
- db $60,$48,$83,$00
- db $60,$50,$93,$00
- db $60,$58,$84,$00
- db $60,$60,$85,$00
- db $60,$68,$83,$00
- db $60,$70,$81,$00
- db $60,$78,$86,$00
+ dbsprite 10, 9, 0, 0, $8d, 0
+ dbsprite 11, 9, 0, 0, $8e, 0
+ dbsprite 10, 10, 0, 0, $8f, 0
+ dbsprite 11, 10, 0, 0, $90, 0
+ dbsprite 10, 11, 0, 0, $91, 0
+ dbsprite 11, 11, 0, 0, $92, 0
+ dbsprite 6, 12, 0, 0, $80, 0
+ dbsprite 7, 12, 0, 0, $81, 0
+ dbsprite 8, 12, 0, 0, $82, 0
+ dbsprite 9, 12, 0, 0, $83, 0
+ dbsprite 10, 12, 0, 0, $93, 0
+ dbsprite 11, 12, 0, 0, $84, 0
+ dbsprite 12, 12, 0, 0, $85, 0
+ dbsprite 13, 12, 0, 0, $83, 0
+ dbsprite 14, 12, 0, 0, $81, 0
+ dbsprite 15, 12, 0, 0, $86, 0
GameFreakLogoOAMDataEnd:
GameFreakShootingStarOAMData:
- db $00,$A0,$A0,$10
- db $00,$A8,$A0,$30
- db $08,$A0,$A1,$10
- db $08,$A8,$A1,$30
+ dbsprite 20, 0, 0, 0, $a0, OAM_OBP1
+ dbsprite 21, 0, 0, 0, $a0, OAM_OBP1 | OAM_HFLIP
+ dbsprite 20, 1, 0, 0, $a1, OAM_OBP1
+ dbsprite 21, 1, 0, 0, $a1, OAM_OBP1 | OAM_HFLIP
GameFreakShootingStarOAMDataEnd:
FallingStar:
diff --git a/engine/movie/hall_of_fame.asm b/engine/movie/hall_of_fame.asm
index 071e7ca1..a7d3ed40 100755
--- a/engine/movie/hall_of_fame.asm
+++ b/engine/movie/hall_of_fame.asm
@@ -202,7 +202,7 @@ HoFLoadPlayerPics:
HoFLoadMonPlayerPicTileIDs:
; c = base tile ID
- ld b, 0
+ ld b, TILEMAP_MON_PIC
hlcoord 12, 5
predef_jump CopyTileIDsFromList
diff --git a/engine/movie/intro.asm b/engine/movie/intro.asm
index 215b54ae..d8ec8e6e 100755
--- a/engine/movie/intro.asm
+++ b/engine/movie/intro.asm
@@ -1,15 +1,10 @@
-const_value = -1
+ const_def -1
const MOVE_NIDORINO_RIGHT
const MOVE_GENGAR_RIGHT
const MOVE_GENGAR_LEFT
ANIMATION_END EQU 80
-const_value = 3
- const GENGAR_INTRO_TILES1
- const GENGAR_INTRO_TILES2
- const GENGAR_INTRO_TILES3
-
PlayIntro:
xor a
ldh [hJoyHeld], a
@@ -34,7 +29,7 @@ PlayIntroScene:
ldh [rOBP1], a
xor a
ldh [hSCX], a
- ld b, GENGAR_INTRO_TILES1
+ ld b, TILEMAP_GENGAR_INTRO_1
call IntroCopyTiles
ld a, 0
ld [wBaseCoordX], a
@@ -77,7 +72,7 @@ PlayIntroScene:
ret c
; raise
- ld b, GENGAR_INTRO_TILES2
+ ld b, TILEMAP_GENGAR_INTRO_2
call IntroCopyTiles
ld a, SFX_INTRO_RAISE
call PlaySound
@@ -88,7 +83,7 @@ PlayIntroScene:
ret c
; slash
- ld b, GENGAR_INTRO_TILES3
+ ld b, TILEMAP_GENGAR_INTRO_3
call IntroCopyTiles
ld a, SFX_INTRO_CRASH
call PlaySound
@@ -107,7 +102,7 @@ PlayIntroScene:
lb de, 8 / 2, MOVE_GENGAR_LEFT
call IntroMoveMon
- ld b, GENGAR_INTRO_TILES1
+ ld b, TILEMAP_GENGAR_INTRO_1
call IntroCopyTiles
ld c, 60
call CheckForUserInterruption
@@ -445,6 +440,7 @@ GameFreakIntroEnd:
FightIntroBackMon:
INCBIN "gfx/intro_credits/gengar.2bpp"
+ ds 16, $00 ; blank tile
FightIntroBackMonEnd:
FightIntroFrontMon:
diff --git a/engine/movie/trade.asm b/engine/movie/trade.asm
index fc2da9bd..fa84e01d 100755
--- a/engine/movie/trade.asm
+++ b/engine/movie/trade.asm
@@ -59,11 +59,11 @@ TradeAnimCommon:
addtradefunc: MACRO
\1TradeFunc::
dw \1
- ENDM
+ENDM
tradefunc: MACRO
db (\1TradeFunc - TradeFuncPointerTable) / 2
- ENDM
+ENDM
; The functions in the sequences below are executed in order by TradeFuncCommon.
; They are from opposite perspectives. The external clock one makes use of
@@ -86,7 +86,7 @@ InternalClockTradeFuncSequence:
tradefunc Trade_ShowEnemyMon
tradefunc Trade_Delay100
tradefunc Trade_Cleanup
- db $FF
+ db -1 ; end
ExternalClockTradeFuncSequence:
tradefunc LoadTradingGFXAndMonNames
@@ -110,7 +110,7 @@ ExternalClockTradeFuncSequence:
tradefunc Trade_ShowClearedWindow
tradefunc PrintTradeWentToText
tradefunc Trade_Cleanup
- db $FF
+ db -1 ; end
TradeFuncPointerTable:
addtradefunc LoadTradingGFXAndMonNames
@@ -282,7 +282,7 @@ Trade_DrawOpenEndOfLinkCable:
ld a, %10001011
ldh [rLCDC], a
hlcoord 6, 2
- ld b, $7 ; open end of link cable tile ID list index
+ ld b, TILEMAP_LINK_CABLE
call CopyTileIDsFromList_ZeroBaseTileID
call Trade_CopyTileMapToVRAM
ld a, SFX_HEAL_HP
@@ -346,8 +346,8 @@ Trade_AnimateBallEnteringLinkCable:
ret
Trade_BallInsideLinkCableOAM:
- db $7E,$00,$7E,$20
- db $7E,$40,$7E,$60
+ dbsprite 0, 15, 0, 6, $7e, OAM_HFLIP
+ dbsprite 8, 15, 0, 6, $7e, OAM_HFLIP | OAM_VFLIP
Trade_ShowEnemyMon:
ld a, TRADE_BALL_TILT_ANIM
@@ -474,7 +474,7 @@ Trade_DrawLeftGameboy:
; draw gameboy pic
hlcoord 5, 3
- ld b, $6
+ ld b, TILEMAP_GAME_BOY
call CopyTileIDsFromList_ZeroBaseTileID
; draw text box with player name below gameboy pic
@@ -521,7 +521,7 @@ Trade_DrawRightGameboy:
; draw gameboy pic
hlcoord 7, 8
- ld b, $6
+ ld b, TILEMAP_GAME_BOY
call CopyTileIDsFromList_ZeroBaseTileID
; draw text box with enemy name above link cable
@@ -697,31 +697,33 @@ Trade_WriteCircleOAM:
jr nz, .loop
ret
+trade_circle_oam: MACRO
+ dw \1
+ db \2, \3
+ENDM
+
Trade_CircleOAMPointers:
- dw Trade_CircleOAM0
- db $08,$08
- dw Trade_CircleOAM1
- db $18,$08
- dw Trade_CircleOAM2
- db $08,$18
- dw Trade_CircleOAM3
- db $18,$18
+ ; oam pointer, upper-left x coord, upper-left y coord
+ trade_circle_oam Trade_CircleOAM0, $08, $08
+ trade_circle_oam Trade_CircleOAM1, $18, $08
+ trade_circle_oam Trade_CircleOAM2, $08, $18
+ trade_circle_oam Trade_CircleOAM3, $18, $18
Trade_CircleOAM0:
- db $38,$10,$39,$10
- db $3A,$10,$3B,$10
+ dbsprite 2, 7, 0, 0, $39, OAM_OBP1
+ dbsprite 2, 7, 0, 2, $3b, OAM_OBP1
Trade_CircleOAM1:
- db $39,$30,$38,$30
- db $3B,$30,$3A,$30
+ dbsprite 6, 7, 0, 1, $38, OAM_OBP1 | OAM_HFLIP
+ dbsprite 6, 7, 0, 3, $3a, OAM_OBP1 | OAM_HFLIP
Trade_CircleOAM2:
- db $3A,$50,$3B,$50
- db $38,$50,$39,$50
+ dbsprite 10, 7, 0, 2, $3b, OAM_OBP1 | OAM_VFLIP
+ dbsprite 10, 7, 0, 0, $39, OAM_OBP1 | OAM_VFLIP
Trade_CircleOAM3:
- db $3B,$70,$3A,$70
- db $39,$70,$38,$70
+ dbsprite 14, 7, 0, 3, $3a, OAM_OBP1 | OAM_HFLIP | OAM_VFLIP
+ dbsprite 14, 7, 0, 1, $38, OAM_OBP1 | OAM_HFLIP | OAM_VFLIP
; a = species
Trade_LoadMonSprite: