summaryrefslogtreecommitdiff
path: root/src/battle/anim/thrashing.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/battle/anim/thrashing.c')
-rw-r--r--src/battle/anim/thrashing.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/battle/anim/thrashing.c b/src/battle/anim/thrashing.c
index bc1fc4842..38dccb83f 100644
--- a/src/battle/anim/thrashing.c
+++ b/src/battle/anim/thrashing.c
@@ -8,14 +8,22 @@ extern s16 gBattleAnimArgs[];
extern u8 gAnimBankAttacker;
extern u8 gAnimBankTarget;
-extern struct AffineAnimFrameCmd gUnknown_083D77B0;
-
static void sub_80D0A8C(u8 taskId);
static void sub_80D0B3C(u8 taskId);
// thrashing (the movement of the Pokemon left/right repeatedly, with up/down movements below.)
// Used by Thrash.
+const union AffineAnimCmd gSpriteAffineAnim_83D77B0[] =
+{
+ AFFINEANIMCMD_FRAME(-10, 9, 0, 7),
+ AFFINEANIMCMD_FRAME(20, -20, 0, 7),
+ AFFINEANIMCMD_FRAME(-20, 20, 0, 7),
+ AFFINEANIMCMD_FRAME(10, -9, 0, 7),
+ AFFINEANIMCMD_LOOP(2),
+ AFFINEANIMCMD_END,
+};
+
// left/right movements
void sub_80D0A4C(u8 taskId)
{
@@ -23,11 +31,11 @@ void sub_80D0A4C(u8 taskId)
u8 spriteId = GetAnimBattlerSpriteId(0);
task->data[0] = spriteId;
task->data[1] = 0;
- sub_80798F4(task, spriteId, &gUnknown_083D77B0);
+ sub_80798F4(task, spriteId, &gSpriteAffineAnim_83D77B0);
task->func = sub_80D0A8C;
}
-void sub_80D0A8C(u8 taskId)
+static void sub_80D0A8C(u8 taskId)
{
struct Task* task = &gTasks[taskId];
if (!sub_807992C(task))
@@ -54,7 +62,7 @@ void sub_80D0AB8(u8 taskId)
task->func = sub_80D0B3C;
}
-void sub_80D0B3C(u8 taskId)
+static void sub_80D0B3C(u8 taskId)
{
struct Task* task = &gTasks[taskId];
if (++task->data[7] > 2)