mirror of
https://github.com/zeldaret/tmc
synced 2026-06-10 04:54:18 -04:00
ResetPlayer decompile
This commit is contained in:
+1
-1
@@ -1256,7 +1256,7 @@ static void PlayerTalkEzlo(Entity* this) {
|
||||
|
||||
static void PlayerTalkEzloInit(Entity* this) {
|
||||
ResetPlayer();
|
||||
gUnk_03000B80.filler[0x63] = 0;
|
||||
gUnk_03000B80[3].field_0xf = 0;
|
||||
this->iframes = 0;
|
||||
gPriorityHandler.sys_priority = PRIO_PLAYER_EVENT;
|
||||
this->updatePriority = PRIO_PLAYER_EVENT;
|
||||
|
||||
@@ -0,0 +1,38 @@
|
||||
#include "player.h"
|
||||
#include "functions.h"
|
||||
|
||||
void ResetPlayer() {
|
||||
u32 index = 0;
|
||||
ItemBehavior* ptr = gUnk_03000B80;
|
||||
do {
|
||||
sub_08077E78(ptr, index);
|
||||
ptr++;
|
||||
index++;
|
||||
} while (index <= 2);
|
||||
|
||||
gPlayerState.field_0x3c[1] = 0;
|
||||
gPlayerState.field_0x1c = 0;
|
||||
gPlayerState.field_0x1f[2] = 0;
|
||||
gPlayerState.field_0x0[1] = 0;
|
||||
gPlayerState.field_0xe = 0;
|
||||
gPlayerState.dash_state = 0;
|
||||
gPlayerState.sword_state = 0;
|
||||
gPlayerState.field_0x3[0] = 0;
|
||||
gPlayerState.heldObject = 0;
|
||||
gPlayerState.flags &= 0xf7fbffff;
|
||||
|
||||
gPlayerEntity.field_0x70.WORD = 0;
|
||||
|
||||
if ((gPlayerState.jump_status & 0xc0) == 0) {
|
||||
gPlayerState.jump_status = 0;
|
||||
}
|
||||
|
||||
switch (gPlayerState.framestate) {
|
||||
case 2:
|
||||
case 3:
|
||||
case 4: {
|
||||
gPlayerState.framestate = 0;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user