mirror of https://github.com/zeldaret/tmc.git
Merge pull request #508 from hatal175/goto2
This commit is contained in:
commit
12f2ec8fd8
|
@ -125,7 +125,7 @@ void sub_08076F64(ItemBehavior* this, u32 idx) {
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
break;
|
return;
|
||||||
case 3:
|
case 3:
|
||||||
gPlayerState.field_0x1c = 4;
|
gPlayerState.field_0x1c = 4;
|
||||||
case 4:
|
case 4:
|
||||||
|
@ -147,31 +147,29 @@ void sub_08076F64(ItemBehavior* this, u32 idx) {
|
||||||
gPlayerEntity.direction = DirectionTurnAround(Direction8FromAnimationState(gPlayerEntity.animationState));
|
gPlayerEntity.direction = DirectionTurnAround(Direction8FromAnimationState(gPlayerEntity.animationState));
|
||||||
gPlayerEntity.speed = 0x80;
|
gPlayerEntity.speed = 0x80;
|
||||||
UpdatePlayerMovement();
|
UpdatePlayerMovement();
|
||||||
break;
|
return;
|
||||||
case 6:
|
case 6:
|
||||||
UpdateItemAnim(this);
|
UpdateItemAnim(this);
|
||||||
if ((this->field_0x5[9] & 0x80) == 0)
|
if ((this->field_0x5[9] & 0x80) == 0)
|
||||||
return;
|
return;
|
||||||
goto case0;
|
|
||||||
break;
|
break;
|
||||||
case 7:
|
case 7:
|
||||||
sub_08077DF4(this, 0x514);
|
sub_08077DF4(this, 0x514);
|
||||||
gPlayerState.field_0x1c = 3;
|
gPlayerState.field_0x1c = 3;
|
||||||
gPlayerState.gustJarSpeed = 0;
|
gPlayerState.gustJarSpeed = 0;
|
||||||
break;
|
return;
|
||||||
case 1:
|
case 1:
|
||||||
case 2:
|
case 2:
|
||||||
default:
|
default:
|
||||||
gPlayerState.field_0x1c = 3;
|
gPlayerState.field_0x1c = 3;
|
||||||
sub_08077DF4(this, 0x514);
|
sub_08077DF4(this, 0x514);
|
||||||
break;
|
return;
|
||||||
case 0:
|
case 0:
|
||||||
case0:
|
|
||||||
gPlayerState.field_0x1c = 0;
|
|
||||||
gPlayerEntity.field_0x70.WORD = 0;
|
|
||||||
DeletePlayerItem(this, idx);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
gPlayerState.field_0x1c = 0;
|
||||||
|
gPlayerEntity.field_0x70.WORD = 0;
|
||||||
|
DeletePlayerItem(this, idx);
|
||||||
}
|
}
|
||||||
|
|
||||||
void (*const ItemGustJar_StateFunctions[])(ItemBehavior* beh, u32) = {
|
void (*const ItemGustJar_StateFunctions[])(ItemBehavior* beh, u32) = {
|
||||||
|
|
|
@ -313,7 +313,6 @@ void sub_080855E8(LilypadLargeEntity* this) {
|
||||||
this->unk_70 -= 0x80;
|
this->unk_70 -= 0x80;
|
||||||
}
|
}
|
||||||
if ((super->collisions & 0xe0) == 0xe0) {
|
if ((super->collisions & 0xe0) == 0xe0) {
|
||||||
// goto _080859D8;
|
|
||||||
u32 tmp2 = this->unk_70;
|
u32 tmp2 = this->unk_70;
|
||||||
if ((s32)this->unk_70 < 0) {
|
if ((s32)this->unk_70 < 0) {
|
||||||
tmp2 += 3;
|
tmp2 += 3;
|
||||||
|
|
11
src/script.c
11
src/script.c
|
@ -1150,10 +1150,13 @@ void ScriptCommand_0807E9E4(Entity* entity, ScriptExecutionContext* context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScriptCommand_0807E9F0(Entity* entity, ScriptExecutionContext* context) {
|
void ScriptCommand_0807E9F0(Entity* entity, ScriptExecutionContext* context) {
|
||||||
u32 tmp;
|
bool32 tmp;
|
||||||
sub_0801E00C();
|
sub_0801E00C();
|
||||||
tmp = 1;
|
tmp = TRUE;
|
||||||
switch (gFuseInfo._0) {
|
switch (gFuseInfo._0) {
|
||||||
|
default:
|
||||||
|
tmp = FALSE;
|
||||||
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
gPlayerState.controlMode = CONTROL_DISABLED;
|
gPlayerState.controlMode = CONTROL_DISABLED;
|
||||||
gPauseMenuOptions.disabled = tmp;
|
gPauseMenuOptions.disabled = tmp;
|
||||||
|
@ -1162,14 +1165,12 @@ void ScriptCommand_0807E9F0(Entity* entity, ScriptExecutionContext* context) {
|
||||||
case 1:
|
case 1:
|
||||||
context->condition = 0;
|
context->condition = 0;
|
||||||
break;
|
break;
|
||||||
default:
|
|
||||||
goto lbl;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tmp) {
|
if (tmp) {
|
||||||
PlayerResetStateFromFusion();
|
PlayerResetStateFromFusion();
|
||||||
gPlayerState.controlMode = CONTROL_1;
|
gPlayerState.controlMode = CONTROL_1;
|
||||||
} else {
|
} else {
|
||||||
lbl:
|
|
||||||
gActiveScriptInfo.commandSize = 0;
|
gActiveScriptInfo.commandSize = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue