mirror of
https://github.com/zeldaret/tmc
synced 2026-05-31 01:16:04 -04:00
30 lines
514 B
C
30 lines
514 B
C
/**
|
|
* @file lamp.c
|
|
* @ingroup Objects
|
|
*
|
|
* @brief Lamp object
|
|
*/
|
|
#include "entity.h"
|
|
|
|
void Lamp_Init(Entity* this);
|
|
void Lamp_Action1(Entity* this);
|
|
|
|
void Lamp(Entity* this) {
|
|
static void (*const Lamp_Actions[])(Entity*) = {
|
|
Lamp_Init,
|
|
Lamp_Action1,
|
|
};
|
|
|
|
Lamp_Actions[this->action](this);
|
|
}
|
|
|
|
void Lamp_Init(Entity* this) {
|
|
this->action = 1;
|
|
UpdateSpriteForCollisionLayer(this);
|
|
InitializeAnimation(this, 0);
|
|
}
|
|
|
|
void Lamp_Action1(Entity* this) {
|
|
GetNextFrame(this);
|
|
}
|