blob: 99b8572fc9788b219bdd6c2da5276d08855ac17b (
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
|
/**
* @file windTribeFlag.c
* @ingroup Objects
*
* @brief Wind Tribe Flag object
*/
#include "object.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;
}
}
|