Skip to content

Commit

Permalink
Updated TriAttack's animation
Browse files Browse the repository at this point in the history
  • Loading branch information
SoupPotato committed Jan 15, 2024
1 parent f155d4a commit c15f36f
Show file tree
Hide file tree
Showing 8 changed files with 90 additions and 12 deletions.
11 changes: 9 additions & 2 deletions constants/battle_anim_constants.asm
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,8 @@ DEF BATTLEANIM_BASE_TILE EQU 7 * 7 ; Maximum size of a pokemon picture
const BATTLE_ANIM_OBJ_OCTAZOOKA_SMOKE ; c2
const BATTLE_ANIM_OBJ_INK_SPLASH ; c3
const BATTLE_ANIM_OBJ_DAZZLE ; c4
const BATTLE_ANIM_OBJ_SHOOTING_TRIANGLE ; c5
const BATTLE_ANIM_OBJ_SPINNING_TRIANGLE ; c6
DEF NUM_BATTLE_ANIM_OBJS EQU const_value

; DoBattleAnimFrame arguments (see engine/battle_anims/functions.asm)
Expand Down Expand Up @@ -508,6 +510,8 @@ DEF NUM_BATTLE_ANIM_FUNCS EQU const_value
const BATTLE_ANIM_FRAMESET_BUBBLE_SPLASH ; bd
const BATTLE_ANIM_FRAMESET_SMOKE_PUFF ; be
const BATTLE_ANIM_FRAMESET_INK_SPLASH ; bf
const BATTLE_ANIM_FRAMESET_SPINNING_TRIANGLE ; c0
const BATTLE_ANIM_FRAMESET_SPINNING_TRIANGLE_SLOW ; c1
DEF NUM_BATTLE_ANIM_FRAMESETS EQU const_value

; BattleAnimOAMData indexes (see data/battle_anims/oam.asm)
Expand Down Expand Up @@ -729,6 +733,8 @@ DEF NUM_BATTLE_ANIM_FRAMESETS EQU const_value
const BATTLE_ANIM_OAMSET_D6
const BATTLE_ANIM_OAMSET_D7
const BATTLE_ANIM_OAMSET_D8
const BATTLE_ANIM_OAMSET_D9
const BATTLE_ANIM_OAMSET_DA
DEF NUM_BATTLE_ANIM_OAMSETS EQU const_value

assert NUM_BATTLE_ANIM_OAMSETS <= FIRST_OAM_CMD, \
Expand Down Expand Up @@ -835,8 +841,9 @@ DEF NUM_BATTLE_BG_EFFECTS EQU const_value - 1
const BATTLE_ANIM_GFX_AEROBLAST ; 27
const BATTLE_ANIM_GFX_BEAM_LIGHT ; 28
const BATTLE_ANIM_GFX_SMOKE_PUFF ; 29
const BATTLE_ANIM_GFX_PLAYERHEAD ; 2a
const BATTLE_ANIM_GFX_ENEMYFEET ; 2b
const BATTLE_ANIM_GFX_TRIANGLE ; 2a
const BATTLE_ANIM_GFX_PLAYERHEAD ; 2b
const BATTLE_ANIM_GFX_ENEMYFEET ; 2c
DEF NUM_BATTLE_ANIM_GFX EQU const_value - 1

; battle_bg_effect struct members (see macros/ram.asm)
Expand Down
34 changes: 25 additions & 9 deletions data/battle_anims/framesets.asm
Original file line number Diff line number Diff line change
Expand Up @@ -184,15 +184,17 @@ BattleAnimFrameData:
dw .Frameset_Sandstorm ; BATTLE_ANIM_FRAMESET_SANDSTORM
dw .Frameset_EnemyFeet1Row ; BATTLE_ANIM_FRAMESET_ENEMYFEET_1ROW
dw .Frameset_PlayerHead1Row ; BATTLE_ANIM_FRAMESET_PLAYERHEAD_1ROW
dw .Frameset_EnemyFeet2Row ; BATTLE_ANIM_FRAMESET_ENEMYFEET_2ROW
dw .Frameset_PlayerHead2Row ; BATTLE_ANIM_FRAMESET_PLAYERHEAD_2ROW
dw .Frameset_MediumHorn ; BATTLE_ANIM_FRAMESET_MEDIUM_HORN
dw .Frameset_SafariBait ; BATTLE_ANIM_FRAMESET_SAFARI_BAIT
dw .Frameset_Recover ; BATTLE_ANIM_FRAMESET_RECOVER
dw .Frameset_Minimize ; BATTLE_ANIM_FRAMESET_MINIMIZE
dw .Frameset_BubbleSplash ; BATTLE_ANIM_FRAMESET_BUBBLE_SPLASH
dw .Frameset_SmokePuff ; BATTLE_ANIM_FRAMESET_SMOKE_PUFF
dw .Frameset_InkSplash ; BATTLE_ANIM_FRAMESET_INK_SPLASH
dw .Frameset_EnemyFeet2Row ; BATTLE_ANIM_FRAMESET_ENEMYFEET_2ROW
dw .Frameset_PlayerHead2Row ; BATTLE_ANIM_FRAMESET_PLAYERHEAD_2ROW
dw .Frameset_MediumHorn ; BATTLE_ANIM_FRAMESET_MEDIUM_HORN
dw .Frameset_SafariBait ; BATTLE_ANIM_FRAMESET_SAFARI_BAIT
dw .Frameset_Recover ; BATTLE_ANIM_FRAMESET_RECOVER
dw .Frameset_Minimize ; BATTLE_ANIM_FRAMESET_MINIMIZE
dw .Frameset_BubbleSplash ; BATTLE_ANIM_FRAMESET_BUBBLE_SPLASH
dw .Frameset_SmokePuff ; BATTLE_ANIM_FRAMESET_SMOKE_PUFF
dw .Frameset_InkSplash ; BATTLE_ANIM_FRAMESET_INK_SPLASH
dw .Frameset_SpinningTriangle ; BATTLE_ANIM_FRAMESET_SPINNING_TRIANGLE
dw .Frameset_SpinningTriangleSlow ; BATTLE_ANIM_FRAMESET_SPINNING_SLOW
assert_table_length NUM_BATTLE_ANIM_FRAMESETS

.Frameset_HitBig:
Expand Down Expand Up @@ -1305,3 +1307,17 @@ BattleAnimFrameData:
.Frameset_InkSplash:
oamframe BATTLE_ANIM_OAMSET_1F, 8
oamend

.Frameset_SpinningTriangle:
oamframe BATTLE_ANIM_OAMSET_D9, 0
oamframe BATTLE_ANIM_OAMSET_DA, 0
oamframe BATTLE_ANIM_OAMSET_D9, 0, OAM_Y_FLIP
oamframe BATTLE_ANIM_OAMSET_DA, 0, OAM_X_FLIP
oamrestart

.Frameset_SpinningTriangleSlow:
oamframe BATTLE_ANIM_OAMSET_D9, 2
oamframe BATTLE_ANIM_OAMSET_DA, 2
oamframe BATTLE_ANIM_OAMSET_D9, 2, OAM_Y_FLIP
oamframe BATTLE_ANIM_OAMSET_DA, 2, OAM_X_FLIP
oamrestart
24 changes: 24 additions & 0 deletions data/battle_anims/oam.asm
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,8 @@ BattleAnimOAMData:
battleanimoam $00, 14, .OAMData_d6 ; BATTLE_ANIM_OAMSET_D6
battleanimoam $00, 12, .OAMData_d7 ; BATTLE_ANIM_OAMSET_D7
battleanimoam $07, 4, .OAMData_03 ; BATTLE_ANIM_OAMSET_D8
battleanimoam $00, 9, .OAMData_d9 ; BATTLE_ANIM_OAMSET_D9
battleanimoam $06, 9, .OAMData_da ; BATTLE_ANIM_OAMSET_DA
assert_table_length NUM_BATTLE_ANIM_OAMSETS

.OAMData_11:
Expand Down Expand Up @@ -1091,3 +1093,25 @@ BattleAnimOAMData:
dbsprite 6, -2, 4, 0, $00, $0
dbsprite 8, -4, 4, 0, $00, $0
dbsprite 10, -2, 4, 0, $00, $0

.OAMData_d9:
dbsprite -2, -2, 4, 4, $00, $0
dbsprite -1, -2, 4, 4, $01, $0
dbsprite 0, -2, 4, 4, $00, X_FLIP
dbsprite -2, -1, 4, 4, $02, $0
dbsprite -1, -1, 4, 4, $03, $0
dbsprite 0, -1, 4, 4, $02, X_FLIP
dbsprite -2, 0, 4, 4, $04, $0
dbsprite -1, 0, 4, 4, $05, $0
dbsprite 0, 0, 4, 4, $04, X_FLIP

.OAMData_da:
dbsprite -2, -2, 4, 4, $00, $0
dbsprite -1, -2, 4, 4, $01, $0
dbsprite 0, -2, 4, 4, $02, $0
dbsprite -2, -1, 4, 4, $03, $0
dbsprite -1, -1, 4, 4, $04, $0
dbsprite 0, -1, 4, 4, $05, $0
dbsprite -2, 0, 4, 4, $00, Y_FLIP
dbsprite -1, 0, 4, 4, $01, Y_FLIP
dbsprite 0, 0, 4, 4, $02, Y_FLIP
1 change: 1 addition & 0 deletions data/battle_anims/object_gfx.asm
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ AnimObjGFX:
anim_obj_gfx 24, AnimObjAeroblastGFX
anim_obj_gfx 10, AnimObjBeamLightGFX
anim_obj_gfx 9, AnimObjSmokePuffGFX
anim_obj_gfx 12, AnimObjTriangleGFX
anim_obj_gfx 1, NULL
anim_obj_gfx 1, NULL
assert_table_length NUM_BATTLE_ANIM_GFX + 1
4 changes: 4 additions & 0 deletions data/battle_anims/objects.asm
Original file line number Diff line number Diff line change
Expand Up @@ -413,4 +413,8 @@ BattleAnimObjects:
battleanimobj RELATIVE_X, $90, BATTLE_ANIM_FRAMESET_INK_SPLASH, BATTLE_ANIM_FUNC_BUBBLE_SPLASH, PAL_BATTLE_OB_GRAY, BATTLE_ANIM_GFX_POISON
; BATTLE_ANIM_OBJ_DAZZLE
battleanimobj RELATIVE_X, $88, BATTLE_ANIM_FRAMESET_SPARKLE, BATTLE_ANIM_FUNC_HIDDEN_POWER, PAL_BATTLE_OB_YELLOW, BATTLE_ANIM_GFX_SPEED
; BATTLE_ANIM_OBJ_SHOOTING_TRIANGLE
battleanimobj RELATIVE_X, $90, BATTLE_ANIM_FRAMESET_SPINNING_TRIANGLE, BATTLE_ANIM_FUNC_USER_TO_TARGET_DISAPPEAR, PAL_BATTLE_OB_GRAY, BATTLE_ANIM_GFX_TRIANGLE
; BATTLE_ANIM_OBJ_SHOOTING_TRIANGLE
battleanimobj RELATIVE_X, $90, BATTLE_ANIM_FRAMESET_SPINNING_TRIANGLE_SLOW, BATTLE_ANIM_FUNC_NULL, PAL_BATTLE_OB_GRAY, BATTLE_ANIM_GFX_TRIANGLE
assert_table_length NUM_BATTLE_ANIM_OBJS
27 changes: 26 additions & 1 deletion data/moves/animations.asm
Original file line number Diff line number Diff line change
Expand Up @@ -2705,7 +2705,32 @@ BattleAnim_Lick:
anim_ret

BattleAnim_TriAttack:
anim_3gfx BATTLE_ANIM_GFX_FIRE, BATTLE_ANIM_GFX_ICE, BATTLE_ANIM_GFX_LIGHTNING
anim_4gfx BATTLE_ANIM_GFX_FIRE, BATTLE_ANIM_GFX_ICE, BATTLE_ANIM_GFX_LIGHTNING, BATTLE_ANIM_GFX_TRIANGLE
anim_bgeffect BATTLE_BG_EFFECT_CYCLE_OBPALS_GRAY_AND_YELLOW, $0, $4, $0
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_FIRE
anim_sound 0, 1, SFX_THIEF_2
anim_obj BATTLE_ANIM_OBJ_SPINNING_TRIANGLE, 48, 98, $0
anim_wait 8
.loop
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_ICE
anim_wait 8
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_YELLOW
anim_wait 8
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_FIRE
anim_wait 8
anim_loop 2, .loop
anim_clearobjs
anim_sound 0, 1, SFX_HYDRO_PUMP
anim_obj BATTLE_ANIM_OBJ_SHOOTING_TRIANGLE, 48, 98, $2
.loop2
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_ICE
anim_wait 7
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_YELLOW
anim_wait 7
anim_setobjpal PAL_BATTLE_OB_GRAY, PAL_BTLCUSTOM_FIRE
anim_wait 7
anim_loop 2, .loop2
anim_bgeffect BATTLE_BG_EFFECT_CYCLE_OBPALS_GRAY_AND_YELLOW, $0, $20, $0
anim_call BattleAnimSub_Fire
anim_wait 16
anim_call BattleAnimSub_Ice
Expand Down
1 change: 1 addition & 0 deletions gfx/battle_anims.asm
Original file line number Diff line number Diff line change
Expand Up @@ -40,3 +40,4 @@ AnimObjMisc2GFX: INCBIN "gfx/battle_anims/misc2.2bpp.lz"
AnimObjAeroblastGFX: INCBIN "gfx/battle_anims/aeroblast.2bpp.lz"
AnimObjBeamLightGFX: INCBIN "gfx/battle_anims/beamlight.2bpp.lz"
AnimObjSmokePuffGFX: INCBIN "gfx/battle_anims/smokepuff.2bpp.lz"
AnimObjTriangleGFX: INCBIN "gfx/battle_anims/triangle.2bpp.lz"
Binary file added gfx/battle_anims/triangle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit c15f36f

Please sign in to comment.