1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2025-07-16 04:44:44 +00:00

Changes in PR #15

- Renamed `prenmi_buff.c` to `z_prenmi_buff.c`
This commit is contained in:
Random 2020-03-20 18:13:47 +01:00
parent 1fe00fcce1
commit 3e764f6ed8
2 changed files with 1 additions and 1 deletions

35
src/code/z_prenmi_buff.c Normal file
View file

@ -0,0 +1,35 @@
#include <ultra64.h>
#include <global.h>
#define COLD_RESET 0
#define NMI 1
void PreNmiBuff_Init(PreNmiBuff* this)
{
this->resetting = false;
if (osResetType == COLD_RESET)
{
this->resetCount = 0;
this->duration = 0;
}
else
{
this->resetCount++;
this->duration += this->resetTime;
}
this->resetTime = 0;
}
void PreNmiBuff_SetReset(PreNmiBuff* this)
{
this->resetting = true;
this->resetTime = osGetTime();
}
u32 PreNmiBuff_IsResetting(PreNmiBuff* this)
{
return this->resetting;
}