Improve Electro Ball animation

This commit is contained in:
DizzyEggg 2020-06-26 13:58:34 +02:00
parent 548a43f8d9
commit 219a43304a
2 changed files with 39 additions and 11 deletions

View File

@ -4834,32 +4834,30 @@ Move_SYCHRONOISE:
Move_ELECTRO_BALL: Move_ELECTRO_BALL:
loadspritegfx ANIM_TAG_SPARK_2 @yelow loadspritegfx ANIM_TAG_SPARK_2 @yelow
loadspritegfx ANIM_TAG_CIRCLE_OF_LIGHT @charge loadspritegfx ANIM_TAG_CIRCLE_OF_LIGHT @charge
monbg 0x0 loadspritegfx ANIM_TAG_FLASH_CANNON_BALL @ball
monbg ANIM_TARGET
setalpha 12, 8 setalpha 12, 8
playsewithpan SE_W268, SOUND_PAN_ATTACKER playsewithpan SE_W268, SOUND_PAN_ATTACKER
launchtemplate gGrowingChargeOrbSpriteTemplate 0x2 0x1 0x0 createsprite gGrowingChargeOrb2SpriteTemplate, ANIM_ATTACKER, 2, 0
delay 0x19 delay 0x19
playsewithpan SE_W268, SOUND_PAN_ATTACKER playsewithpan SE_W268, SOUND_PAN_ATTACKER
delay 0x14 delay 0x14
playsewithpan SE_W268, SOUND_PAN_ATTACKER playsewithpan SE_W268, SOUND_PAN_ATTACKER
delay 0xF delay 0xF
playsewithpan SE_W268, SOUND_PAN_ATTACKER playsewithpan SE_W268, SOUND_PAN_ATTACKER
delay 0xA
delay 0x6 delay 0x6
loopsewithpan SE_W268, 0xC, 0x6, 0x5 loopsewithpan SE_W268, 0xC, 0x6, 0x5
waitforvisualfinish waitforvisualfinish
loadspritegfx ANIM_TAG_FLASH_CANNON_BALL @ball createsprite gElectroBallCannonBallTemplate, ANIM_TARGET, 2, 16, 16, 8
launchtemplate gElectroBallCannonBallTemplate, ANIM_TARGET, 2, 0x10, 0x10, 0x8
waitforvisualfinish waitforvisualfinish
playsewithpan SE_W028, SOUND_PAN_TARGET playsewithpan SE_W028, SOUND_PAN_TARGET
createvisualtask AnimTask_ShakeMon2, 0x2, 0x1, 0x4, 0x0, 0x8, 0x1 createvisualtask AnimTask_ShakeMon2, 0x2, ANIM_TARGET, 0x4, 0x0, 0x8, 0x1
call ElectricityEffect call ElectricityEffect
waitforvisualfinish waitforvisualfinish
clearmonbg 0x0 clearmonbg ANIM_TARGET
blendoff blendoff
end end
Move_SOAK: Move_SOAK:
loadspritegfx ANIM_TAG_SMALL_BUBBLES loadspritegfx ANIM_TAG_SMALL_BUBBLES
loadspritegfx ANIM_TAG_WATER_IMPACT loadspritegfx ANIM_TAG_WATER_IMPACT

View File

@ -342,6 +342,19 @@ static const union AffineAnimCmd sAffineAnim_GrowingElectricOrb_2[] =
AFFINEANIMCMD_END, AFFINEANIMCMD_END,
}; };
static const union AffineAnimCmd sAffineAnim_GrowingElectricOrb_4[] =
{
AFFINEANIMCMD_FRAME(5, 5, 0, 0),
AFFINEANIMCMD_FRAME(0x2, 0x2, 0, 20),
AFFINEANIMCMD_FRAME(0x3, 0x3, 0, 15),
AFFINEANIMCMD_FRAME(0x1, 0x1, 0, 25),
AFFINEANIMCMD_FRAME(0xFFFC, 0xFFFC, 0, 5),
AFFINEANIMCMD_FRAME(0x3, 0x3, 0, 5),
AFFINEANIMCMD_FRAME(0xFFFB, 0xFFFB, 0, 5),
AFFINEANIMCMD_FRAME(0x4, 0x4, 0, 5),
AFFINEANIMCMD_END
};
const union AffineAnimCmd *const gAffineAnims_GrowingElectricOrb[] = const union AffineAnimCmd *const gAffineAnims_GrowingElectricOrb[] =
{ {
sAffineAnim_GrowingElectricOrb_0, sAffineAnim_GrowingElectricOrb_0,
@ -349,6 +362,11 @@ const union AffineAnimCmd *const gAffineAnims_GrowingElectricOrb[] =
sAffineAnim_GrowingElectricOrb_2, sAffineAnim_GrowingElectricOrb_2,
}; };
const union AffineAnimCmd *const gAffineAnims_GrowingElectricOrb2[] =
{
sAffineAnim_GrowingElectricOrb_4,
};
const struct SpriteTemplate gGrowingChargeOrbSpriteTemplate = const struct SpriteTemplate gGrowingChargeOrbSpriteTemplate =
{ {
.tileTag = ANIM_TAG_CIRCLE_OF_LIGHT, .tileTag = ANIM_TAG_CIRCLE_OF_LIGHT,
@ -360,6 +378,18 @@ const struct SpriteTemplate gGrowingChargeOrbSpriteTemplate =
.callback = AnimGrowingChargeOrb, .callback = AnimGrowingChargeOrb,
}; };
// For Electro Ball - smaller orb.
const struct SpriteTemplate gGrowingChargeOrb2SpriteTemplate =
{
.tileTag = ANIM_TAG_CIRCLE_OF_LIGHT,
.paletteTag = ANIM_TAG_CIRCLE_OF_LIGHT,
.oam = &gOamData_AffineNormal_ObjBlend_64x64,
.anims = gDummySpriteAnimTable,
.images = NULL,
.affineAnims = gAffineAnims_GrowingElectricOrb2,
.callback = AnimGrowingChargeOrb,
};
static const union AnimCmd sAnim_ElectricPuff[] = static const union AnimCmd sAnim_ElectricPuff[] =
{ {
ANIMCMD_FRAME(0, 3), ANIMCMD_FRAME(0, 3),