blob: deac4c3987576df31ce3914443f8fe3064c9fb44 (
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
|
/**
* @file windTribeFlag.c
* @ingroup Objects
*
* @brief Wind Tribe Flag object
*/
#include "object.h"
#include "asm.h"
void WindTribeFlag(Entity* this) {
if (this->action == 0) {
this->action++;
this->collisionLayer = 2;
if (this->type == 0) {
this->spriteSettings.flipX = 0;
} else {
this->spriteSettings.flipX = 1;
}
UpdateSpriteForCollisionLayer(this);
InitializeAnimation(this, 0);
} else {
GetNextFrame(this);
}
if (this->frameDuration == 0xff) {
this->frameDuration = (Random() & 0xf) + 0x10;
}
}
|