diff options
| author | Tal Hayon <talhayon1@gmail.com> | 2022-08-07 00:39:22 +0300 |
|---|---|---|
| committer | Tal Hayon <talhayon1@gmail.com> | 2022-08-07 00:39:22 +0300 |
| commit | c45195c57754b1c802a2bae3e473df01bed4cd85 (patch) | |
| tree | 1002df8b88f17536bed64c74a62115bb55c6d369 /src/object | |
| parent | 807d313e10be369240a1309f7ffe63c143f87287 (diff) | |
Use negative values where appropriate
Diffstat (limited to 'src/object')
| -rw-r--r-- | src/object/bigBarrel.c | 8 | ||||
| -rw-r--r-- | src/object/chestSpawner.c | 2 | ||||
| -rw-r--r-- | src/object/gleerokParticle.c | 4 | ||||
| -rw-r--r-- | src/object/keyStealingTakkuri.c | 4 | ||||
| -rw-r--r-- | src/object/lilypadLarge.c | 2 | ||||
| -rw-r--r-- | src/object/litArea.c | 4 | ||||
| -rw-r--r-- | src/object/stoneTablet.c | 7 |
7 files changed, 16 insertions, 15 deletions
diff --git a/src/object/bigBarrel.c b/src/object/bigBarrel.c index 6b12f308..f40c90a3 100644 --- a/src/object/bigBarrel.c +++ b/src/object/bigBarrel.c @@ -109,7 +109,7 @@ void sub_08088BE0(BigBarrelEntity* this) { Entity* ent; if (CheckLocalFlag(0x15) == 0) { - sub_08088C78(this, 2, 0, 0xffffff88); + sub_08088C78(this, 2, 0, -120); ent = sub_08088C78(this, 4, 0x15, 0); if (ent != NULL) { ent->x.HALF.HI = gRoomControls.origin_x + 0x48; @@ -118,15 +118,15 @@ void sub_08088BE0(BigBarrelEntity* this) { } if (CheckLocalFlag(0x16) == 0) { - sub_08088C78(this, 2, 1, 0x78); + sub_08088C78(this, 2, 1, 120); ent = sub_08088C78(this, 4, 0x16, 0); if (ent != NULL) { ent->x.HALF.HI = gRoomControls.origin_x + 0x188; ent->y.HALF.HI = gRoomControls.origin_y + 200; } } - sub_08088C78(this, 1, 0, 0xffffff88); - sub_08088C78(this, 1, 1, 0x78); + sub_08088C78(this, 1, 0, -120); + sub_08088C78(this, 1, 1, 120); } Entity* sub_08088C78(BigBarrelEntity* this, u32 type, u32 type2, u32 xOffset) { diff --git a/src/object/chestSpawner.c b/src/object/chestSpawner.c index 899b336f..dfe03a92 100644 --- a/src/object/chestSpawner.c +++ b/src/object/chestSpawner.c @@ -201,7 +201,7 @@ void sub_080840A8(s32 param_1, s32 param_2) { obj->zVelocity = gUnk_0811F840[Random() & 3]; obj->x.HALF.HI = gUnk_0811F850[Random() & 3] + param_1; obj->y.HALF.HI = param_2 + 1; - obj->z.HALF.HI = 0xfff8; + obj->z.HALF.HI = -8; ResolveCollisionLayer(obj); obj = CreateFx(obj, FX_DASH, 0); if (obj != NULL) { diff --git a/src/object/gleerokParticle.c b/src/object/gleerokParticle.c index 93462377..e878f2a1 100644 --- a/src/object/gleerokParticle.c +++ b/src/object/gleerokParticle.c @@ -323,11 +323,11 @@ void sub_08094660(GleerokParticleEntity* this) { sub_08094708(this, iVar3, iVar4); iVar3 = super->x.HALF.HI + spriteOffsetX + 0x30; iVar4 = super->y.HALF.HI + spriteOffsetX + 0x30; - this->unk78 = 0xfffffff0; + this->unk78 = -16; this->unk7c = 0; sub_08094708(this, iVar3, iVar4); this->unk78 = 0; - this->unk7c = 0xfffffff0; + this->unk7c = -16; sub_08094708(this, iVar3, iVar4); } } diff --git a/src/object/keyStealingTakkuri.c b/src/object/keyStealingTakkuri.c index 68fac5a3..1cc970ca 100644 --- a/src/object/keyStealingTakkuri.c +++ b/src/object/keyStealingTakkuri.c @@ -378,7 +378,7 @@ void KeyStealingTakkuri_Type4_Init(KeyStealingTakkuriEntity* this) { super->action++; super->collisionLayer = 1; super->spriteRendering.b3 = 1; - super->z.HALF.HI = 0xfff0; + super->z.HALF.HI = -16; sub_0807DD64(super); InitAnimationForceUpdate(super, 1); } @@ -396,7 +396,7 @@ void sub_0809E0A0(KeyStealingTakkuriEntity* this) { super->child = obj; super->subtimer = 0; CopyPosition(&gPlayerEntity, obj); - obj->z.HALF.HI = 0xfff8; + obj->z.HALF.HI = -8; } } diff --git a/src/object/lilypadLarge.c b/src/object/lilypadLarge.c index a36f8277..154402d0 100644 --- a/src/object/lilypadLarge.c +++ b/src/object/lilypadLarge.c @@ -347,7 +347,7 @@ void sub_08085A44(LilypadLargeEntity* this) { if (GetRelativeCollisionTile(super, 0x10, 0x18) != 0x11) { super->direction = 0x18; } else { - if (GetRelativeCollisionTile(super, 0xfffffff0, 0x18) != 0x11) { + if (GetRelativeCollisionTile(super, -0x10, 0x18) != 0x11) { super->direction = 8; } else { super->direction = 0x10; diff --git a/src/object/litArea.c b/src/object/litArea.c index 74c14e5b..b615672c 100644 --- a/src/object/litArea.c +++ b/src/object/litArea.c @@ -23,7 +23,7 @@ void LitArea(Entity* this) { this->flags |= ENT_PERSIST; this->subtimer = gRoomControls.room; this->timer = 2; - this->field_0x68.HWORD = 0xfffe; + this->field_0x68.HWORD = -2; this->field_0x6a.HWORD = 0x80; SetAffineInfo(this, 0x80, 0x80, 0); } else { @@ -34,7 +34,7 @@ void LitArea(Entity* this) { this->field_0x68.HWORD = 1; } if (0x88 < this->field_0x6a.HWORD) { - this->field_0x68.HWORD = 0xffff; + this->field_0x68.HWORD = -1; } SetAffineInfo(this, this->field_0x6a.HWORD, this->field_0x6a.HWORD, 0); } diff --git a/src/object/stoneTablet.c b/src/object/stoneTablet.c index ad01fcda..06049ca9 100644 --- a/src/object/stoneTablet.c +++ b/src/object/stoneTablet.c @@ -22,9 +22,10 @@ void StoneTablet(Entity* this) { void StoneTablet_Init(Entity* this) { // TODO recreate as TileData[] - static const u16 gUnk_081232EC[] = { 0x4022, 0xfffe, 0x4022, 0xffff, 0x4022, 0x0, 0x4022, 0x1, 0xffff }; - static const u16 gUnk_081232FE[] = { 0x4065, 0xffbf, 0x4022, 0xffc0, 0x4066, 0xffc1, 0x4029, - 0xffff, 0x4026, 0x0, 0x402a, 0x1, 0xffff }; + static const u16 gUnk_081232EC[] = { 0x4022, -2, 0x4022, -1, 0x4022, 0, 0x4022, 1, 0xffff }; + static const u16 gUnk_081232FE[] = { + 0x4065, -65, 0x4022, -64, 0x4066, -63, 0x4029, -1, 0x4026, 0, 0x402a, 1, 0xffff + }; this->action = 1; this->spriteSettings.draw = 1; if (this->type == 3) { |
