diff options
| author | Behemoth <Luisscheurenbrand@gmail.com> | 2020-08-18 01:43:09 +0200 |
|---|---|---|
| committer | Behemoth <Luisscheurenbrand@gmail.com> | 2020-08-18 01:43:09 +0200 |
| commit | debf6b20957027e122aed600937a69b5e8fd2b76 (patch) | |
| tree | 3bd53f1b1bbc3ea13af4aadb19729af338c56dca /src/object | |
| parent | 79cb86022ecd20cb3696588c634ecfd29b0dd08b (diff) | |
Decompile Acro-Bandits
Diffstat (limited to 'src/object')
| -rw-r--r-- | src/object/fan.c | 8 | ||||
| -rw-r--r-- | src/object/lightableSwitch.c | 4 | ||||
| -rw-r--r-- | src/object/mask.c | 4 | ||||
| -rw-r--r-- | src/object/metalDoor.c | 20 | ||||
| -rw-r--r-- | src/object/railtrack.c | 10 |
5 files changed, 23 insertions, 23 deletions
diff --git a/src/object/fan.c b/src/object/fan.c index 481e3887..c73cec9b 100644 --- a/src/object/fan.c +++ b/src/object/fan.c @@ -31,7 +31,7 @@ void sub_0809ED54(Entity *this) if (((this->cutsceneBeh.HWORD == 0) || CheckFlags(this->cutsceneBeh.HWORD)) && ((this->entityType.parameter != 1 || - (--this->field_0x74 == 0)))) { + (--this->field_0x74.HWORD == 0)))) { sub_0809EE08(this); } } @@ -52,7 +52,7 @@ void sub_0809ED88(Entity *this) sub_0809EE24(this); } else if (((this->entityType).parameter == 1) && - (--this->field_0x74 == 0)) { + (--this->field_0x74.HWORD == 0)) { sub_0809EE24(this); } } @@ -69,7 +69,7 @@ void sub_0809EDE4(Entity *this) void sub_0809EE08(Entity *this) { this->action = 2; - this->field_0x74 = *((u8 *)&this->field_0x7c + 3) << 2; + this->field_0x74.HWORD = *((u8 *)&this->field_0x7c + 3) << 2; InitializeAnimation(this, this->entityType.form); } @@ -82,5 +82,5 @@ void sub_0809EE24(Entity *this) void sub_0809EE34(Entity *this) { this->action = 1; - this->field_0x74 = this->actionDelay << 2; + this->field_0x74.HWORD = this->actionDelay << 2; }
\ No newline at end of file diff --git a/src/object/lightableSwitch.c b/src/object/lightableSwitch.c index 2368da04..e9a1e8e0 100644 --- a/src/object/lightableSwitch.c +++ b/src/object/lightableSwitch.c @@ -73,7 +73,7 @@ void sub_0809EAD8(Entity* this) { if (this->entityType.parameter != 0) { this->attachedEntity = GetCurrentRoomProperty(this->entityType.parameter); - sub_080A2CC0(this, &this->attachedEntity, &this->field_0x74); + sub_080A2CC0(this, &this->attachedEntity, &this->field_0x74.HWORD); } else { SetTile(0x4050, COORD_TO_TILE(this), this->collisionLayer); @@ -88,7 +88,7 @@ void sub_0809EB30(Entity* this) { if ((this->direction & 0x80) == 0) { sub_0806F69C(this); } - puVar2 = &this->field_0x74; + puVar2 = &this->field_0x74.HWORD; if (!--*puVar2) { sub_080A2CC0(this, &this->attachedEntity, puVar2); } diff --git a/src/object/mask.c b/src/object/mask.c index dfabc160..675805b8 100644 --- a/src/object/mask.c +++ b/src/object/mask.c @@ -68,7 +68,7 @@ void sub_080929A4(Entity *this) { this->field_0x7c.HALF.HI = COORD_TO_TILE(this); this->field_0x7c.HALF.LO = sub_080001DA(this->field_0x7c.HALF.HI, 1); - this->field_0x7a = sub_080002E0(this->field_0x7c.HALF.HI, 1); + this->field_0x7a.HWORD = sub_080002E0(this->field_0x7c.HALF.HI, 1); SetTile(0x4022, this->field_0x7c.HALF.HI, 1); } @@ -96,7 +96,7 @@ void sub_08092A94(Entity *this) { // Presumably, make the mask fall SetTile((u16)this->field_0x7c.HALF.LO, this->field_0x7c.HALF.HI, 1); - sub_08000148(this->field_0x7a, this->field_0x7c.HALF.HI, 1); + sub_08000148(this->field_0x7a.HWORD, this->field_0x7c.HALF.HI, 1); this->action = 2; diff --git a/src/object/metalDoor.c b/src/object/metalDoor.c index 1f18a272..381bf0d8 100644 --- a/src/object/metalDoor.c +++ b/src/object/metalDoor.c @@ -34,7 +34,7 @@ void sub_080A0684(Entity *this) this->spritePriority.b0 = 5; this->field_0x70.HALF.LO = this->x.HALF.HI; this->field_0x70.HALF.HI = this->y.HALF.HI; - this->field_0x74 = COORD_TO_TILE(this); + this->field_0x74.HWORD = COORD_TO_TILE(this); } void sub_080A0718(Entity *this) @@ -99,17 +99,17 @@ void sub_080A07F0(Entity *this) void sub_080A080C(Entity *this) { - this->field_0x76 = sub_080001DA(this->field_0x74 - 1, this->collisionLayer); - this->field_0x78.HWORD = sub_080001DA(this->field_0x74, this->collisionLayer); - this->field_0x7a = sub_080001DA(this->field_0x74 + 1, this->collisionLayer); - SetTile(0x4022, this->field_0x74 - 1, this->collisionLayer); - SetTile(0x4022, this->field_0x74, this->collisionLayer); - SetTile(0x4022, this->field_0x74 + 1, this->collisionLayer); + this->field_0x76.HWORD = sub_080001DA(this->field_0x74.HWORD - 1, this->collisionLayer); + this->field_0x78.HWORD = sub_080001DA(this->field_0x74.HWORD, this->collisionLayer); + this->field_0x7a.HWORD = sub_080001DA(this->field_0x74.HWORD + 1, this->collisionLayer); + SetTile(0x4022, this->field_0x74.HWORD - 1, this->collisionLayer); + SetTile(0x4022, this->field_0x74.HWORD, this->collisionLayer); + SetTile(0x4022, this->field_0x74.HWORD + 1, this->collisionLayer); } void sub_080A0870(Entity *this) { - SetTile(this->field_0x76, this->field_0x74 - 1, this->collisionLayer); - SetTile(this->field_0x78.HWORD, this->field_0x74, this->collisionLayer); - SetTile(this->field_0x7a, this->field_0x74 + 1, this->collisionLayer); + SetTile(this->field_0x76.HWORD, this->field_0x74.HWORD - 1, this->collisionLayer); + SetTile(this->field_0x78.HWORD, this->field_0x74.HWORD, this->collisionLayer); + SetTile(this->field_0x7a.HWORD, this->field_0x74.HWORD + 1, this->collisionLayer); }
\ No newline at end of file diff --git a/src/object/railtrack.c b/src/object/railtrack.c index f2e9a10a..05b8a2aa 100644 --- a/src/object/railtrack.c +++ b/src/object/railtrack.c @@ -33,7 +33,7 @@ void sub_080851AC(Entity* this) { this->animationState = this->entityType.parameter & 2; if ((this->entityType).form == 3) { uVar1 = CheckFlags(this->field_0x86); - this->field_0x7a = uVar1; + this->field_0x7a.HWORD = uVar1; if ((u16)(uVar1 & -1) != 0) { this->animationState = (this->animationState + 2) & 3; this->action = 3; @@ -62,7 +62,7 @@ void sub_080852B4(Entity* this) { if (--this->field_0xf == 0) { this->action = 3; this->field_0xf = this->actionDelay; - this->field_0x7a = CheckFlags(this->field_0x86); + this->field_0x7a.HWORD = CheckFlags(this->field_0x86); this->animationState = (this->animationState + *(u8*)&this->field_0x7c) & 3; InitializeAnimation(this, this->animationState); sub_08085394(this); @@ -114,7 +114,7 @@ void sub_08085394(Entity *this) iVar3 = this->animationState / 2; layerData = *(u16 **)&this->field_0x70; uVar4 = COORD_TO_TILE(this); - this->field_0x74 = layerData[gUnk_080B4488[iVar3]]; + this->field_0x74.HWORD = layerData[gUnk_080B4488[iVar3]]; pbVar5 = &this->collisionLayer; SetTile(uVar1, uVar4 - iVar3, *pbVar5); this->field_0x76 = layerData[0]; @@ -137,8 +137,8 @@ void sub_0808543C(Entity *this) temp = gUnk_080B4488[this->animationState / 2][0]; uVar2 = COORD_TO_TILE(this); - SetTile(this->field_0x74, uVar2 - temp, this->collisionLayer); - SetTile(this->field_0x76, uVar2, this->collisionLayer); + SetTile(this->field_0x74.HWORD, uVar2 - temp, this->collisionLayer); + SetTile(this->field_0x76.HWORD, uVar2, this->collisionLayer); SetTile(this->field_0x78.HWORD, uVar2 + temp, this->collisionLayer); } |
