mirror of
https://github.com/zeldaret/tmc
synced 2026-07-09 14:55:35 -04:00
quick fix 🙂
This commit is contained in:
@@ -18,7 +18,7 @@ void sub_0808F658(Entity* this) {
|
||||
this->spritePriority.b0 = this->type;
|
||||
this->frameIndex = this->type;
|
||||
this->direction = 8;
|
||||
this->nonPlanarMovement = gUnk_08121EB0[this->type];
|
||||
this->speed = gUnk_08121EB0[this->type];
|
||||
this->field_0x78.HWORD = gRoomControls.roomOriginX - 0x60;
|
||||
this->field_0x7a.HWORD = gRoomControls.roomOriginX + gRoomControls.width + 0x60;
|
||||
this->animationState = 0;
|
||||
|
||||
+1
-1
@@ -28,7 +28,7 @@ void sub_0809CF54(Entity* this) {
|
||||
this->field_0x20 = -0x18000;
|
||||
this->height.WORD = -0x38C000;
|
||||
this->field_0x68.HWORD = -0x800;
|
||||
this->nonPlanarMovement = 0x280;
|
||||
this->speed = 0x280;
|
||||
this->direction = 8;
|
||||
this->collisionLayer = 2;
|
||||
this->x.HALF.HI = gRoomControls.roomScrollX;
|
||||
|
||||
+1
-1
@@ -180,7 +180,7 @@ void sub_0809F7BC(Entity* this) {
|
||||
cloud = sub_0809F770(this);
|
||||
if (cloud != NULL) {
|
||||
uVar1 = Random();
|
||||
cloud->nonPlanarMovement = gUnk_081247C8[uVar1 & 3];
|
||||
cloud->speed = gUnk_081247C8[uVar1 & 3];
|
||||
cloud->direction = (u8)(uVar1 >> 8) & 31;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -506,7 +506,7 @@ static u32 sub_0808EF6C(Entity* this) {
|
||||
if (this->field_0x6c.HWORD < var7) {
|
||||
var7 = this->field_0x6c.HWORD;
|
||||
}
|
||||
this->nonPlanarMovement = var7;
|
||||
this->speed = var7;
|
||||
this->direction = sub_080045DA(var0, var2) >> 3;
|
||||
sub_0806F69C(this);
|
||||
return 1;
|
||||
@@ -517,7 +517,7 @@ static void sub_0808EFF0(Entity* this) {
|
||||
u8 var1;
|
||||
|
||||
this->spriteSettings.b.draw = 2;
|
||||
this->nonPlanarMovement = 0x400;
|
||||
this->speed = 0x400;
|
||||
this->currentHealth = 1;
|
||||
this->frameIndex = 0xFF;
|
||||
this->animIndex = 0xFF;
|
||||
|
||||
@@ -159,21 +159,21 @@ void GreatFairy_WingsInit(Entity* this) {
|
||||
this->spriteRendering.alphaBlend = 1;
|
||||
gScreen.controls.layerFXControl = 0xF40;
|
||||
gScreen.controls.alphaBlend = BLDALPHA_BLEND(9, 8);
|
||||
this->nonPlanarMovement = 1024;
|
||||
this->speed = 1024;
|
||||
sub_0805EC9C(this, 1024, 256, 0);
|
||||
}
|
||||
|
||||
void GreatFairy_WingsUpdate(Entity* this) {
|
||||
s32 iVar1;
|
||||
|
||||
iVar1 = this->nonPlanarMovement -= 32;
|
||||
iVar1 = this->speed -= 32;
|
||||
if (iVar1 * 65536 >> 16 == 256) {
|
||||
this->action = 2;
|
||||
sub_0805EC60(this);
|
||||
gRoomVars.greatFairyState |= 32;
|
||||
gActiveScriptInfo.unk_00 |= 4;
|
||||
} else {
|
||||
sub_0805EC9C(this, this->nonPlanarMovement, 256, 0);
|
||||
sub_0805EC9C(this, this->speed, 256, 0);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -260,7 +260,7 @@ void GreatFairy_MiniAffineInit2(Entity* this) {
|
||||
if (this->height.HALF.HI == -20) {
|
||||
this->action = 2;
|
||||
this->actionDelay = 90;
|
||||
this->nonPlanarMovement = 4096;
|
||||
this->speed = 4096;
|
||||
this->spriteRendering.b0 = 3;
|
||||
sub_0805EC9C(this, 256, 256, 0);
|
||||
}
|
||||
@@ -275,7 +275,7 @@ void GreatFairy_MiniAffineUpdate(Entity* this) {
|
||||
this->action = 3;
|
||||
sub_0805EC60(this);
|
||||
} else {
|
||||
iVar2 = this->nonPlanarMovement -= 24;
|
||||
iVar2 = this->speed -= 24;
|
||||
sub_0805EC9C(this, 256, iVar2 * 0x10000 >> 20, 0);
|
||||
}
|
||||
}
|
||||
@@ -386,7 +386,7 @@ void sub_08087150(Entity* this) {
|
||||
this->spriteOrientation.flipY = 0;
|
||||
this->spriteRendering.b0 = 0;
|
||||
this->spritePriority.b0 = 3;
|
||||
this->nonPlanarMovement = 0x80;
|
||||
this->speed = 0x80;
|
||||
this->direction = 0x10;
|
||||
temp = gUnk_0812079C;
|
||||
this->palette.raw = ((temp & 0xf) << 4) | 0xf;
|
||||
@@ -463,7 +463,7 @@ void sub_080872AC(Entity* this) {
|
||||
this->field_0x68.HWORD = this->x.HALF.HI;
|
||||
this->field_0x6a.HWORD = this->y.HALF.HI;
|
||||
this->direction = (u8)Random() & 0x1F;
|
||||
this->nonPlanarMovement = 32;
|
||||
this->speed = 32;
|
||||
GreatFairy_InitializeAnimation(this);
|
||||
}
|
||||
|
||||
|
||||
@@ -141,8 +141,8 @@ static void sub_080810A8(Entity* this) {
|
||||
sub_080814A4(this);
|
||||
if (this->direction & 0x80) {
|
||||
this->direction &= 0x1F;
|
||||
if (this->nonPlanarMovement == 0) {
|
||||
this->nonPlanarMovement = 0x100;
|
||||
if (this->speed == 0) {
|
||||
this->speed = 0x100;
|
||||
}
|
||||
} else {
|
||||
this->direction |= 0xFF;
|
||||
@@ -259,7 +259,7 @@ void sub_080812A0(Entity* this) {
|
||||
void sub_080812A8(Entity* this) {
|
||||
if (sub_080002D0(this) != 0xF && this->field_0x6e.HWORD != GetTileTypeByEntity(this)) {
|
||||
this->direction = 0;
|
||||
this->nonPlanarMovement = 0;
|
||||
this->speed = 0;
|
||||
this->spriteSettings.b.draw = 1;
|
||||
this->field_0x68.HALF.HI = 0;
|
||||
sub_080810A8(this);
|
||||
|
||||
@@ -25,7 +25,7 @@ void sub_080A0684(Entity* this) {
|
||||
DeleteThisEntity();
|
||||
}
|
||||
this->action = 1;
|
||||
this->nonPlanarMovement = 0x300;
|
||||
this->speed = 0x300;
|
||||
this->spriteSettings.b.draw = 0;
|
||||
this->frameIndex = 0;
|
||||
this->spriteSettings.b.flipY = 1;
|
||||
|
||||
@@ -51,7 +51,7 @@ void sub_080916EC(Entity* this) {
|
||||
this->field_0x40 = 0x44;
|
||||
this->flags2 = 0x80;
|
||||
this->direction = DirectionFromAnimationState(this->animationState);
|
||||
this->nonPlanarMovement = 0x700;
|
||||
this->speed = 0x700;
|
||||
this->spritePriority.b1 = 3;
|
||||
InitAnimationForceUpdate(this, this->type2 + 4 + this->animationState);
|
||||
SetTile(0x4022, COORD_TO_TILE(this), this->collisionLayer);
|
||||
@@ -81,7 +81,7 @@ void sub_080917DC(Entity* this) {
|
||||
gPlayerState.jumpStatus = 0x81;
|
||||
gPlayerState.flags.all |= 0x4000000;
|
||||
gPlayerEntity.field_0x20 = 0x20000;
|
||||
gPlayerEntity.nonPlanarMovement = 0x100;
|
||||
gPlayerEntity.speed = 0x100;
|
||||
gPlayerEntity.flags &= 0x7f;
|
||||
ResetPlayer();
|
||||
sub_0807A108();
|
||||
@@ -143,7 +143,7 @@ void sub_080919AC(Entity* this) {
|
||||
}
|
||||
} else {
|
||||
this->flags = this->flags | 0x80;
|
||||
gPlayerEntity.nonPlanarMovement = 0;
|
||||
gPlayerEntity.speed = 0;
|
||||
sub_0806F69C(this);
|
||||
CopyPosition(this, &gPlayerEntity);
|
||||
gPlayerEntity.spritePriority.b0 = this->spritePriority.b0 - 1;
|
||||
@@ -176,7 +176,7 @@ void sub_080919AC(Entity* this) {
|
||||
gPlayerState.jumpStatus = 0x41;
|
||||
gPlayerState.flags.all = (gPlayerState.flags.all ^ 0x1000) | 0x4000000;
|
||||
gPlayerEntity.field_0x20 = 0x20000;
|
||||
gPlayerEntity.nonPlanarMovement = 0x200;
|
||||
gPlayerEntity.speed = 0x200;
|
||||
gPlayerEntity.animationState = this->animationState << 1;
|
||||
gPlayerEntity.direction = this->direction;
|
||||
gPlayerEntity.flags |= 0x80;
|
||||
|
||||
@@ -54,5 +54,5 @@ void sub_08086A6C(Entity* ent) {
|
||||
uVar1 = Random();
|
||||
ent->field_0x20 = 163840;
|
||||
ent->direction = (uVar1 >> 16) & 31;
|
||||
ent->nonPlanarMovement = uVar1 & 480;
|
||||
ent->speed = uVar1 & 480;
|
||||
}
|
||||
|
||||
@@ -105,6 +105,6 @@ void sub_0809F448(Entity* this) {
|
||||
tmp += -0x80000 + (rand & 0xFFFFF);
|
||||
break;
|
||||
}
|
||||
this->nonPlanarMovement = (tmp > 0 ? tmp : -tmp) / (tmp2->unk_1 << 8);
|
||||
this->speed = (tmp > 0 ? tmp : -tmp) / (tmp2->unk_1 << 8);
|
||||
this->direction = sub_080045DA(tmp, 0) >> 3;
|
||||
}
|
||||
|
||||
@@ -22,12 +22,12 @@ void ObjectB2(Entity* this) {
|
||||
this->attachedEntity = pEVar3;
|
||||
InitializeAnimation(this, this->type);
|
||||
}
|
||||
this->nonPlanarMovement = this->parent->nonPlanarMovement;
|
||||
this->speed = this->parent->speed;
|
||||
sub_0806F69C(this);
|
||||
if (sub_080AE4CC(this->attachedEntity, this->x.HALF.HI, this->y.HALF.HI, 9) != 0) {
|
||||
DeleteThisEntity();
|
||||
}
|
||||
if (this->nonPlanarMovement < 0x41) {
|
||||
if (this->speed < 0x41) {
|
||||
this->spriteSettings.b.draw ^= 1;
|
||||
|
||||
if (--this->actionDelay == 0) {
|
||||
|
||||
+3
-3
@@ -34,7 +34,7 @@ void sub_0808222C(Entity* this) {
|
||||
|
||||
this->action = 1;
|
||||
this->hitbox = &gUnk_080FD338;
|
||||
this->nonPlanarMovement = 0x80;
|
||||
this->speed = 0x80;
|
||||
this->y.HALF.HI += 3;
|
||||
this->field_0x16 = 0;
|
||||
this->flags |= 0x80;
|
||||
@@ -86,7 +86,7 @@ void sub_08082310(Entity* this) {
|
||||
this->actionDelay = 32;
|
||||
this->action = 4;
|
||||
if (gPlayerState.flags.all & 0x80) {
|
||||
this->nonPlanarMovement >>= 1;
|
||||
this->speed >>= 1;
|
||||
this->actionDelay = 64;
|
||||
}
|
||||
SetTile((u16)this->field_0x70.HALF.LO, COORD_TO_TILE(this), this->collisionLayer);
|
||||
@@ -185,7 +185,7 @@ void sub_08082614(Entity* this) {
|
||||
|
||||
this->action = 1;
|
||||
if (gPlayerState.flags.all & 0x80) {
|
||||
this->nonPlanarMovement <<= 1;
|
||||
this->speed <<= 1;
|
||||
}
|
||||
|
||||
this->field_0x70.HALF.LO = sub_080001DA(COORD_TO_TILE(this), this->collisionLayer);
|
||||
|
||||
+1
-1
@@ -37,7 +37,7 @@ void sub_0808A46C(Entity* this) {
|
||||
void sub_0808A484(Entity* this) {
|
||||
this->action = 1;
|
||||
this->spriteSettings.b.draw = TRUE;
|
||||
this->nonPlanarMovement = 0x40;
|
||||
this->speed = 0x40;
|
||||
this->direction = 6;
|
||||
this->spriteRendering.b3 = 1;
|
||||
this->spritePriority.b0 = 0;
|
||||
|
||||
Reference in New Issue
Block a user