diff options
| author | notyourav <65437533+notyourav@users.noreply.github.com> | 2022-03-06 23:45:25 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-03-06 23:45:25 -0800 |
| commit | 12e8722606b1bb8686949f7f7e6afd3b495e985a (patch) | |
| tree | 4c74394f238c006bdbeabaa07bdb7fbcfdc2d8fa /src | |
| parent | 4e94e1fbc321b8d98da0f55624b46cfcc6a415a0 (diff) | |
| parent | a7ad4afebdc464500dee3c440bf3321b2c9cc5c8 (diff) | |
Merge pull request #434 from hatal175/field_0xac
rename and retype RoomVars field_0xac
Diffstat (limited to 'src')
| -rw-r--r-- | src/npc/rem.c | 12 | ||||
| -rw-r--r-- | src/object/pressurePlate.c | 2 | ||||
| -rw-r--r-- | src/object/pushableStatue.c | 8 |
3 files changed, 11 insertions, 11 deletions
diff --git a/src/npc/rem.c b/src/npc/rem.c index 4e551d35..3353060d 100644 --- a/src/npc/rem.c +++ b/src/npc/rem.c @@ -414,18 +414,18 @@ void sub_0806AA50(Entity* this, ScriptExecutionContext* context) { MessageNoOverlap(messageIndex, this); switch (context->intVariable) { case 0: - gRoomVars.field_0xac[0] = this; + gRoomVars.entities[0] = this; PrependEntityToList(this, NPC); this->zVelocity = 0x18000; break; case 1: - pEnt = FindNextDuplicateID(gRoomVars.field_0xac[0], NPC); - gRoomVars.field_0xac[1] = pEnt; + pEnt = FindNextDuplicateID(gRoomVars.entities[0], NPC); + gRoomVars.entities[1] = pEnt; pEnt->zVelocity = 0x18000; break; case 2: - pEnt = FindNextDuplicateID(gRoomVars.field_0xac[1], NPC); - gRoomVars.field_0xac[2] = pEnt; + pEnt = FindNextDuplicateID(gRoomVars.entities[1], NPC); + gRoomVars.entities[2] = pEnt; pEnt->zVelocity = 0x18000; break; } @@ -436,7 +436,7 @@ void sub_0806AA50(Entity* this, ScriptExecutionContext* context) { context->unk_18 = 1; break; case 1: - pEnt = ((Entity*)gRoomVars.field_0xac[context->intVariable]); + pEnt = gRoomVars.entities[context->intVariable]; if (pEnt->z.HALF.HI < 0) { break; } diff --git a/src/object/pressurePlate.c b/src/object/pressurePlate.c index 556a0344..b3231615 100644 --- a/src/object/pressurePlate.c +++ b/src/object/pressurePlate.c @@ -102,7 +102,7 @@ static u32 sub_08088938(PressurePlateEntity* this) { x = super->x.HALF.HI - 8; y = super->y.HALF.HI - 8; for (i = 0; i < 8; ++i) { - Entity* e = gRoomVars.field_0xac[i]; + Entity* e = gRoomVars.entities[i]; if (e != NULL) { if ((u16)(e->x.HALF.HI - x) < 0x11 && ((u16)(e->y.HALF_U.HI - y) < 0x11)) { e->spriteOffsetY = sSpriteOffsets[this->dir]; diff --git a/src/object/pushableStatue.c b/src/object/pushableStatue.c index 824450fc..f499f565 100644 --- a/src/object/pushableStatue.c +++ b/src/object/pushableStatue.c @@ -175,8 +175,8 @@ void sub_08089454(PushableStatueEntity* this) { void sub_080894C8(PushableStatueEntity* this) { u32 index; for (index = 0; index < 8; index++) { - if (gRoomVars.field_0xac[index] == NULL) { - gRoomVars.field_0xac[index] = this; + if (gRoomVars.entities[index] == NULL) { + gRoomVars.entities[index] = super; break; } } @@ -185,8 +185,8 @@ void sub_080894C8(PushableStatueEntity* this) { void sub_080894FC(PushableStatueEntity* this) { u32 index; for (index = 0; index <= 7; index++) { - if (this == (PushableStatueEntity*)gRoomVars.field_0xac[index]) { - gRoomVars.field_0xac[index] = NULL; + if (super == gRoomVars.entities[index]) { + gRoomVars.entities[index] = NULL; break; } } |
