blob: 011aa68ceb214623a61b6e1304932a93a4eba280 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#include "global.h"
#include "rom_8077ABC.h"
#include "trig.h"
#include "battle_anim.h"
#include "sound.h"
extern s16 gBattleAnimArgs[];
extern u8 gAnimBankAttacker;
extern u8 gAnimBankTarget;
// anger (anger emotes, usually above the Pokemon's head, indicating annoyed emotions.)
// Used in Frustration, Rage, Swagger, Torment, and Taunt.
void sub_80D09C0(struct Sprite* sprite)
{
u8 bank;
if (gBattleAnimArgs[0] == 0)
bank = gAnimBankAttacker;
else
bank = gAnimBankTarget;
if (GetBankSide(bank) == 1)
{
gBattleAnimArgs[1] *= -1;
}
sprite->pos1.x = GetBankPosition(bank, 2) + gBattleAnimArgs[1];
sprite->pos1.y = GetBankPosition(bank, 3) + gBattleAnimArgs[2];
if (sprite->pos1.y <= 7)
sprite->pos1.y = 8;
StoreSpriteCallbackInData(sprite, move_anim_8074EE0);
sprite->callback = sub_80785E4;
}
|