summaryrefslogtreecommitdiff
path: root/src/enemy
diff options
context:
space:
mode:
authoroctorock <79596758+octorock@users.noreply.github.com>2024-01-06 18:22:00 +0100
committeroctorock <79596758+octorock@users.noreply.github.com>2024-01-06 18:43:02 +0100
commit1ecc23d534d65f918f3fedb690bde4d7b67b0505 (patch)
tree7cdcd98e7302a4acefad7d73d75c1e678f65acd3 /src/enemy
parent560dfa45b16d5da212174423d71c67f638366cce (diff)
Fix format
Diffstat (limited to 'src/enemy')
-rw-r--r--src/enemy/armos.c2
-rw-r--r--src/enemy/businessScrub.c1
-rw-r--r--src/enemy/eyegore.c7
-rw-r--r--src/enemy/gyorgMale.c4
-rw-r--r--src/enemy/octorokBoss.c11
-rw-r--r--src/enemy/tektite.c2
6 files changed, 13 insertions, 14 deletions
diff --git a/src/enemy/armos.c b/src/enemy/armos.c
index 9fdc9d3b..94236dee 100644
--- a/src/enemy/armos.c
+++ b/src/enemy/armos.c
@@ -425,7 +425,7 @@ bool32 sub_0803086C(ArmosEntity* this) {
centerY = super->y.HALF_U.HI - gRoomControls.origin_y;
// TODO for some reason the 0x3f of COORD_TO_TILE(super) needs to be forced to r2 here.
tilePos = ((((((super)->x.HALF.HI) - gRoomControls.origin_x) >> 4) & (r2 = 0x3f)) |
- (((((super)->y.HALF.HI) - gRoomControls.origin_y) >> 4) & r2) << 6);
+ (((((super)->y.HALF.HI) - gRoomControls.origin_y) >> 4) & r2) << 6);
if (GetTileTypeAtTilePos(tilePos, super->collisionLayer) == SPECIAL_TILE_73) {
if (CheckPlayerInRegion(centerX, centerY, 2, 0xc) != 0) {
diff --git a/src/enemy/businessScrub.c b/src/enemy/businessScrub.c
index d386672f..3f2c5c74 100644
--- a/src/enemy/businessScrub.c
+++ b/src/enemy/businessScrub.c
@@ -15,7 +15,6 @@
#include "save.h"
#include "tiles.h"
-
struct SalesOffering {
u8 field_0x0;
u8 field_0x1;
diff --git a/src/enemy/eyegore.c b/src/enemy/eyegore.c
index 590f081f..03b1c90e 100644
--- a/src/enemy/eyegore.c
+++ b/src/enemy/eyegore.c
@@ -401,11 +401,10 @@ void sub_08031024(EyegoreEntity* this) {
} else {
tmp2 = this->unk_7b >> 1;
uVar5 = GetTileTypeAtWorldCoords(super->x.HALF.HI + gUnk_080CE2C0[tmp2],
- super->y.HALF.HI + gUnk_080CE2C0[tmp2 + 1], super->collisionLayer);
+ super->y.HALF.HI + gUnk_080CE2C0[tmp2 + 1], super->collisionLayer);
uVar8 = GetTileTypeAtWorldCoords(super->x.HALF.HI + gUnk_080CE2C0[tmp2 + 2],
- super->y.HALF.HI + gUnk_080CE2C0[tmp2 + 3], super->collisionLayer);
- if (!(((gMapTileTypeToCollisionData[uVar5] == 0) &&
- (gMapTileTypeToCollisionData[uVar8] == 0)) ||
+ super->y.HALF.HI + gUnk_080CE2C0[tmp2 + 3], super->collisionLayer);
+ if (!(((gMapTileTypeToCollisionData[uVar5] == 0) && (gMapTileTypeToCollisionData[uVar8] == 0)) ||
((this->unk_7b | 1) & 1) == 0)) {
if (super->direction >> 3 == super->animationState) {
this->unk_78 |= 0x20;
diff --git a/src/enemy/gyorgMale.c b/src/enemy/gyorgMale.c
index bcbe32ba..d4d52e95 100644
--- a/src/enemy/gyorgMale.c
+++ b/src/enemy/gyorgMale.c
@@ -1070,8 +1070,8 @@ void sub_08047EA4(GyorgMaleEntity* this, u32 unk1) {
if (this->unk_7c & 1) {
tmp2 = sub_08047F68(this) << 8;
dir = CalculateDirectionFromOffsets(gPlayerEntity.base.x.HALF.HI - super->x.HALF.HI,
-
- gPlayerEntity.base.y.HALF.HI - super->y.HALF.HI);
+
+ gPlayerEntity.base.y.HALF.HI - super->y.HALF.HI);
tmp = dir - (tmp / 256);
tmp &= 0xFF;
gPlayerEntity.base.x.WORD += (gSineTable[tmp] - gSineTable[dir]) * tmp2;
diff --git a/src/enemy/octorokBoss.c b/src/enemy/octorokBoss.c
index 306b611b..e0d377f8 100644
--- a/src/enemy/octorokBoss.c
+++ b/src/enemy/octorokBoss.c
@@ -690,9 +690,9 @@ void OctorokBoss_Action1_AimTowardsPlayer(OctorokBossEntity* this) {
s32 tmp1;
s32 tmp2;
- tmp1 =
- (u8)(CalculateDirectionFromOffsets(gPlayerEntity.base.x.WORD - super->x.WORD, gPlayerEntity.base.y.WORD - super->y.WORD) -
- (((u8)(-this->angle.HALF.HI) ^ 0x80)));
+ tmp1 = (u8)(CalculateDirectionFromOffsets(gPlayerEntity.base.x.WORD - super->x.WORD,
+ gPlayerEntity.base.y.WORD - super->y.WORD) -
+ (((u8)(-this->angle.HALF.HI) ^ 0x80)));
if (IS_FROZEN(this) == FALSE) {
tmp2 = 8;
} else {
@@ -900,8 +900,9 @@ void OctorokBoss_ExecuteAttackVacuum(OctorokBossEntity* this) {
if (this->unk_80 == 0) {
super->direction =
-
- CalculateDirectionFromOffsets(gPlayerEntity.base.x.WORD - super->x.WORD, gPlayerEntity.base.y.WORD - super->y.WORD);
+
+ CalculateDirectionFromOffsets(gPlayerEntity.base.x.WORD - super->x.WORD,
+ gPlayerEntity.base.y.WORD - super->y.WORD);
tmp = ((u8) - (this->angle.HALF.HI + 0x80)) - super->direction;
if (tmp < 0) {
tmp = -tmp;
diff --git a/src/enemy/tektite.c b/src/enemy/tektite.c
index e5989987..fbc4c756 100644
--- a/src/enemy/tektite.c
+++ b/src/enemy/tektite.c
@@ -165,7 +165,7 @@ void sub_0802F300(TektiteEntity* this) {
} else if (super->collisions != COL_NONE) {
sub_0800417E(super, super->collisions);
} else if ((GetActTileAtEntity(super) & 0xf0) == 0x50) { // ACT_TILE_240 and ACT_TILE_241?
- super->direction = (super->direction + 0x10) & (0x3 | DirectionNorthWest);
+ super->direction = (super->direction + 0x10) & (0x3 | DirectionNorthWest);
}
if (--super->timer == 0) {