mirror of
https://github.com/zeldaret/tmc
synced 2026-09-03 10:21:18 -04:00
Match festari/sub_0805FE48
This commit is contained in:
+40
-44
@@ -1,5 +1,6 @@
|
||||
#include "global.h"
|
||||
#include "entity.h"
|
||||
#include "functions.h"
|
||||
#include "npc.h"
|
||||
#include "link.h"
|
||||
|
||||
@@ -30,58 +31,53 @@ void sub_0805FE10(Entity *this)
|
||||
sub_0807DD50(this);
|
||||
}
|
||||
|
||||
#if NON_MATCHING
|
||||
void sub_0805FE48(Entity *this)
|
||||
{
|
||||
u8 bVar1;
|
||||
u16 uVar2;
|
||||
u32 uVar3;
|
||||
u32 uVar4;
|
||||
u8 bVar1;
|
||||
u16 uVar2;
|
||||
u32 uVar3;
|
||||
u32 uVar4;
|
||||
|
||||
if (this->interactType == 2) {
|
||||
this->action = 2;
|
||||
this->interactType = 0;
|
||||
InitAnimationForceUpdate(this, sub_0806F5A4(GetFacingDirection(this, &gLinkEntity)));
|
||||
sub_0806F118(this);
|
||||
}
|
||||
else {
|
||||
ExecuteScriptCommandSet(this, *(void **)&this->cutsceneBeh);
|
||||
sub_0805FF2C(this, *(void **)&this->cutsceneBeh);
|
||||
if (this->field_0x80 < 8) {
|
||||
if ((this->field_0x82 & 1) != 0) {
|
||||
uVar4 = (uVar4 & 0xfc) + (this->field_0xf >> 1);
|
||||
}
|
||||
else {
|
||||
uVar4 = (uVar4 & 0xfc) + (this->animationState >> 1);
|
||||
this->field_0xf = this->animationState;
|
||||
}
|
||||
if (this->interactType == 2) {
|
||||
this->action = 2;
|
||||
this->interactType = 0;
|
||||
InitAnimationForceUpdate(this, sub_0806F5A4(GetFacingDirection(this, &gLinkEntity)));
|
||||
sub_0806F118(this);
|
||||
}
|
||||
if (uVar4 != this->animIndex) {
|
||||
InitAnimationForceUpdate(this, uVar4);
|
||||
}
|
||||
UpdateAnimationSingleFrame(this);
|
||||
else {
|
||||
ExecuteScriptCommandSet(this, *(void **)&this->cutsceneBeh);
|
||||
sub_0805FF2C(this, *(void **)&this->cutsceneBeh);
|
||||
uVar4 = this->field_0x80.HWORD;
|
||||
if (uVar4 < 8) {
|
||||
if ((this->field_0x82.HWORD & 1) != 0) {
|
||||
uVar4 = (uVar4 & 0xfc) + (this->field_0xf >> 1);
|
||||
}
|
||||
else {
|
||||
uVar4 = (uVar4 & 0xfc) + (this->animationState >> 1);
|
||||
this->field_0xf = this->animationState;
|
||||
}
|
||||
}
|
||||
if (uVar4 != this->animIndex) {
|
||||
InitAnimationForceUpdate(this, uVar4);
|
||||
}
|
||||
UpdateAnimationSingleFrame(this);
|
||||
|
||||
if (this->frames.b.f3)
|
||||
{
|
||||
switch (this->animIndex) {
|
||||
case 8:
|
||||
case 10:
|
||||
case 11:
|
||||
case 12:
|
||||
this->field_0x80 = 0;
|
||||
if (this->frames.b.f3)
|
||||
{
|
||||
switch (this->animIndex) {
|
||||
case 8:
|
||||
case 10:
|
||||
case 11:
|
||||
case 12:
|
||||
this->field_0x80.HWORD = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if ((this->field_0x82.HWORD & (~this->field_0x82.HWORD + 1)) == 2) {
|
||||
sub_0806ED78(this);
|
||||
}
|
||||
}
|
||||
if ((this->field_0x82 & (~this->field_0x82 + 1)) == 2) {
|
||||
sub_0806ED78(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
#else
|
||||
NAKED
|
||||
void sub_0805FE48(Entity *this) {
|
||||
asm(".include \"asm/non_matching/festari/sub_0805FE48.inc\"");
|
||||
}
|
||||
#endif
|
||||
|
||||
void sub_0805FF18(Entity *this)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user