merge upstream

This commit is contained in:
theo3
2023-12-30 17:25:11 -08:00
507 changed files with 14444 additions and 14095 deletions
+14 -15
View File
@@ -4,7 +4,6 @@
*
* @brief Ambient Clouds object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "effects.h"
#include "entity.h"
@@ -83,12 +82,12 @@ void AmbientClouds_Action1(Entity* this) {
this->spriteOrientation.flipY = 1;
this->spriteRendering.b3 = 0;
if ((this->type2 == 1) || (this->child->action == 2)) {
if (gPlayerEntity.z.HALF.HI < -0x24)
if (gPlayerEntity.base.z.HALF.HI < -0x24)
this->timer = 1;
else
this->timer = 0;
this->y.HALF.HI += (this->type2 - 1) * -0x24;
if (EntityInRectRadius(this, &gPlayerEntity, 15, 15) && (this->timer != 0)) {
if (EntityInRectRadius(this, &gPlayerEntity.base, 15, 15) && (this->timer != 0)) {
this->action = 2;
this->spriteOrientation.flipY = 2;
this->spriteRendering.b3 = 3;
@@ -96,23 +95,23 @@ void AmbientClouds_Action1(Entity* this) {
this->child->action = 1;
}
gPlayerState.field_0x14 = 1;
gPlayerEntity.y.HALF.HI -= 0x24;
gPlayerEntity.z.HALF.HI += 0x24;
sub_0807AA80(&gPlayerEntity);
gPlayerEntity.base.y.HALF.HI -= 0x24;
gPlayerEntity.base.z.HALF.HI += 0x24;
sub_0807AA80(&gPlayerEntity.base);
if (this->subtimer == 0) {
Entity* fx = CreateFx(&gPlayerEntity, FX_DEATH, 0);
Entity* fx = CreateFx(&gPlayerEntity.base, FX_DEATH, 0);
if (fx != NULL) {
fx->x.HALF.HI += 8;
}
fx = CreateFx(&gPlayerEntity, FX_DEATH, 0);
fx = CreateFx(&gPlayerEntity.base, FX_DEATH, 0);
if (fx != NULL) {
fx->x.HALF.HI -= 8;
}
fx = CreateFx(&gPlayerEntity, FX_DEATH, 0);
fx = CreateFx(&gPlayerEntity.base, FX_DEATH, 0);
if (fx != NULL) {
fx->y.HALF.HI += 8;
}
fx = CreateFx(&gPlayerEntity, FX_DEATH, 0);
fx = CreateFx(&gPlayerEntity.base, FX_DEATH, 0);
if (fx != NULL) {
fx->y.HALF.HI -= 8;
}
@@ -126,20 +125,20 @@ void AmbientClouds_Action1(Entity* this) {
void AmbientClouds_Action2(Entity* this) {
this->y.HALF.HI += this->type2 * -0x24;
if (EntityInRectRadius(this, &gPlayerEntity, 15, 15)) {
if (EntityInRectRadius(this, &gPlayerEntity.base, 15, 15)) {
gPlayerState.field_0x14 = 1;
gPlayerState.flags |= PL_FLAGS2;
} else {
this->action = 1;
gPlayerEntity.z.HALF_U.HI += this->z.HALF_U.HI;
gPlayerEntity.y.HALF_U.HI -= this->z.HALF_U.HI;
gPlayerEntity.collisionLayer = 1;
gPlayerEntity.base.z.HALF_U.HI += this->z.HALF_U.HI;
gPlayerEntity.base.y.HALF_U.HI -= this->z.HALF_U.HI;
gPlayerEntity.base.collisionLayer = 1;
}
this->y.HALF.HI += this->type2 * 0x24;
}
void AmbientClouds_Action3(Entity* this) {
if (EntityInRectRadius(this, &gPlayerEntity, 15, 15)) {
if (EntityInRectRadius(this, &gPlayerEntity.base, 15, 15)) {
gPlayerState.field_0x14 = 1;
}
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Angry Statue object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "hitbox.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Archway object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "game.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief BackgroundCloud object
*/
#define NENT_DEPRECATED
#include "object.h"
typedef struct {
+7 -8
View File
@@ -4,7 +4,6 @@
*
* @brief Baker Oven object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -76,15 +75,15 @@ void BakerOven_Action1(BakerOvenEntity* this) {
}
/* Damage minish link if he touches a steam cloud */
if (super->subtimer == 0 && gPlayerEntity.iframes == 0 && super->frameIndex &&
sub_0806FC80(super, &gPlayerEntity, 4)) {
if (super->subtimer == 0 && gPlayerEntity.base.iframes == 0 && super->frameIndex &&
sub_0806FC80(super, &gPlayerEntity.base, 4)) {
super->subtimer++;
ModHealth(-2);
SoundReqClipped(&gPlayerEntity, SFX_PLY_VO6);
gPlayerEntity.iframes = 16;
gPlayerEntity.knockbackDirection = 16;
gPlayerEntity.knockbackDuration = 12;
gPlayerEntity.knockbackSpeed = 16;
SoundReqClipped(&gPlayerEntity.base, SFX_PLY_VO6);
gPlayerEntity.base.iframes = 16;
gPlayerEntity.base.knockbackDirection = 16;
gPlayerEntity.base.knockbackDuration = 12;
gPlayerEntity.base.knockbackSpeed = 16;
}
}
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Barrel Inside object
*/
#define NENT_DEPRECATED
#include "entity.h"
typedef struct {
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Barrel Spiderweb object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "object.h"
@@ -44,7 +43,7 @@ void BarrelSpiderweb_Init(Entity* this) {
this->flags2 = 4;
this->hitbox = (Hitbox*)&gHitbox_0;
this->frameIndex = 2;
this->collisionLayer = gPlayerEntity.collisionLayer;
this->collisionLayer = gPlayerEntity.base.collisionLayer;
sub_0808BDB0(this);
this->y.HALF.HI = 0x170 - (this->parent)->zVelocity;
sub_0808BBE0(this);
@@ -116,9 +115,9 @@ void BarrelSpiderweb_Action2(Entity* this) {
SetAffineInfo(this, 0x200 - this->subtimer, 0x200 - this->subtimer, 0);
}
if (this->contactFlags == 0x93) {
this->direction = GetFacingDirection(this, &gPlayerEntity);
this->direction = GetFacingDirection(this, &gPlayerEntity.base);
LinearMoveUpdate(this);
if (EntityWithinDistance(this, gPlayerEntity.x.HALF.HI, gPlayerEntity.y.HALF.HI - 6, 0x1c)) {
if (EntityWithinDistance(this, gPlayerEntity.base.x.HALF.HI, gPlayerEntity.base.y.HALF.HI - 6, 0x1c)) {
sub_0808BD00(this);
}
} else {
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Beanstalk object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -276,7 +275,7 @@ void Beanstalk_Action1Type7(BeanstalkEntity* this) {
case 3:
case 4:
if (gPlayerState.floor_type == SURFACE_LADDER) {
if (EntityInRectRadius(super, &gPlayerEntity, 0, 8)) {
if (EntityInRectRadius(super, &gPlayerEntity.base, 0, 8)) {
if ((super->animIndex == (super->type2 - 1) * 3 + 1) && (super->timer == 0)) {
super->timer = 1;
InitializeAnimation(super, super->animIndex + 1);
@@ -335,8 +334,8 @@ void Beanstalk_Action1Type9(BeanstalkEntity* this) {
super->y.HALF.HI += 0x28;
this->unk_72 = sub_080B1A0C(super, 0, -0x18);
}
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
if (gPlayerState.floor_type == SURFACE_LADDER) {
super->spritePriority.b0 = 0;
if (sub_080B1A0C(super, 0, -0x18) != 0x4014) {
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Bed Cover object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Bell object
*/
#define NENT_DEPRECATED
#include "object.h"
void Bell_Init(Entity* this);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Bench object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "player.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Big Barrel object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "common.h"
#include "entity.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Big Ice Block object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "item.h"
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Big Pushable Lever object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -59,9 +58,9 @@ void BigPushableLever_Idle(BigPushableLeverEntity* this) {
gPlayerState.pushedObject = 0x98;
gPlayerState.queued_action = PLAYER_PUSH;
gPlayerState.flags |= PL_BUSY;
gPlayerEntity.x.HALF.LO = 0;
gPlayerEntity.y.HALF.LO = 0;
gPlayerEntity.direction = gPlayerEntity.animationState << 2;
gPlayerEntity.base.x.HALF.LO = 0;
gPlayerEntity.base.y.HALF.LO = 0;
gPlayerEntity.base.direction = gPlayerEntity.base.animationState << 2;
}
}
}
+5 -6
View File
@@ -4,7 +4,6 @@
*
* @brief Big Vortex object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "functions.h"
@@ -76,12 +75,12 @@ void BigVortex_Action2(BigVortexEntity* this) {
void BigVortex_Action3(BigVortexEntity* this) {
if (sub_0800419C(super, &gPlayerEntity, 8, 8) != 0) {
CopyPosition(super, &gPlayerEntity);
if (sub_0800419C(super, &gPlayerEntity.base, 8, 8) != 0) {
CopyPosition(super, &gPlayerEntity.base);
sub_08004542(super);
sub_08004542(&gPlayerEntity);
gPlayerEntity.collisionLayer = 1;
SortEntityAbove(super, &gPlayerEntity);
sub_08004542(&gPlayerEntity.base);
gPlayerEntity.base.collisionLayer = 1;
SortEntityAbove(super, &gPlayerEntity.base);
gPlayerState.queued_action = PLAYER_PARACHUTE;
gPlayerState.field_0x38 = 1;
gPlayerState.field_0x39 = super->type2;
+18 -19
View File
@@ -4,7 +4,6 @@
*
* @brief Bird object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "functions.h"
#include "game.h"
@@ -212,26 +211,26 @@ void Bird_Type8(BirdEntity* this) {
super->spriteRendering.b3 = 0;
super->spriteOrientation.flipY = 1;
super->x.HALF.HI = gRoomControls.scroll_x;
super->y.HALF.HI = gPlayerEntity.y.HALF.HI;
super->y.HALF.HI = gPlayerEntity.base.y.HALF.HI;
super->child = NULL;
SetEntityPriority(super, 6);
InitAnimationForceUpdate(super, 0);
SoundReq(0x123);
break;
case 1:
super->collisionLayer = gPlayerEntity.collisionLayer;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->speed += 8;
if (super->speed > 0x300) {
super->speed = 0x300;
}
if ((gPlayerEntity.flags & ENT_COLLIDE) && (gMessage.state & MESSAGE_ACTIVE) == 0 &&
gPlayerEntity.action != PLAYER_SLEEP && gPlayerEntity.action != PLAYER_BOUNCE &&
gPlayerEntity.action != PLAYER_MINISH && gPlayerState.framestate != PL_STATE_CLIMB &&
if ((gPlayerEntity.base.flags & ENT_COLLIDE) && (gMessage.state & MESSAGE_ACTIVE) == 0 &&
gPlayerEntity.base.action != PLAYER_SLEEP && gPlayerEntity.base.action != PLAYER_BOUNCE &&
gPlayerEntity.base.action != PLAYER_MINISH && gPlayerState.framestate != PL_STATE_CLIMB &&
gPlayerState.framestate != PL_STATE_JUMP && gPlayerState.framestate != PL_STATE_PARACHUTE &&
PlayerCanBeMoved() && (EntityInRectRadius(super, &gPlayerEntity, 0xe, 0xe))) {
s32 z = gPlayerEntity.z.HALF.HI - super->z.HALF.HI - 8;
if ((u16)z < 0x20 && gPlayerEntity.health != 0) {
PlayerCanBeMoved() && (EntityInRectRadius(super, &gPlayerEntity.base, 0xe, 0xe))) {
s32 z = gPlayerEntity.base.z.HALF.HI - super->z.HALF.HI - 8;
if ((u16)z < 0x20 && gPlayerEntity.base.health != 0) {
pEVar5 = CreateObject(BIRD, 10, 0);
if (pEVar5 != NULL) {
super->child = pEVar5;
@@ -245,8 +244,8 @@ void Bird_Type8(BirdEntity* this) {
PutAwayItems();
gPlayerState.swim_state = 0;
gPlayerState.jump_status = 0;
gPlayerEntity.flags &= ~0x80;
gPlayerEntity.spriteSettings.draw = 0;
gPlayerEntity.base.flags &= ~0x80;
gPlayerEntity.base.spriteSettings.draw = 0;
gPriorityHandler.event_priority = 6;
gPauseMenuOptions.disabled = 1;
}
@@ -255,7 +254,7 @@ void Bird_Type8(BirdEntity* this) {
break;
default:
PausePlayer();
gPlayerEntity.spriteSettings.draw = 0;
gPlayerEntity.base.spriteSettings.draw = 0;
break;
}
LinearMoveUpdate(super);
@@ -263,7 +262,7 @@ void Bird_Type8(BirdEntity* this) {
UpdateAnimationSingleFrame(super);
pEVar5 = super->child;
if (pEVar5 != NULL) {
if (gPlayerEntity.x.HALF.HI < super->x.HALF.HI - 8) {
if (gPlayerEntity.base.x.HALF.HI < super->x.HALF.HI - 8) {
super->timer = 0;
}
@@ -275,7 +274,7 @@ void Bird_Type8(BirdEntity* this) {
pEVar5->spriteOrientation.flipY = super->spriteOrientation.flipY;
} else {
super->timer--;
CopyPosition(&gPlayerEntity, pEVar5);
CopyPosition(&gPlayerEntity.base, pEVar5);
}
}
@@ -309,13 +308,13 @@ void Bird_Type9(BirdEntity* this) {
super->spriteOrientation.flipY = 1;
SetEntityPriority(super, 6);
super->x.HALF.HI = gRoomControls.scroll_x;
super->y.HALF.HI = gPlayerEntity.y.HALF.HI;
super->y.HALF.HI = gPlayerEntity.base.y.HALF.HI;
SoundReq(SFX_123);
super->spritePriority.b1 = 2;
InitAnimationForceUpdate(super, 0);
PausePlayer();
} else if (super->action == 1) {
gPlayerEntity.spriteSettings.draw = 0;
gPlayerEntity.base.spriteSettings.draw = 0;
child = super->child;
if (child != NULL) {
PositionRelative(super, child, Q_16_16(-8), 0);
@@ -331,8 +330,8 @@ void Bird_Type9(BirdEntity* this) {
if (child != NULL) {
child->action++;
}
gRoomControls.camera_target = &gPlayerEntity;
gPlayerEntity.spriteSettings.draw = 1;
gRoomControls.camera_target = &gPlayerEntity.base;
gPlayerEntity.base.spriteSettings.draw = 1;
ResetPlayerAnimationAndAction();
ResetPlayerEventPriority();
gPauseMenuOptions.disabled = 0;
@@ -355,7 +354,7 @@ void Bird_Type9(BirdEntity* this) {
}
void Bird_Type10(BirdEntity* this) {
super->palette.b.b0 = gPlayerEntity.palette.b.b0;
super->palette.b.b0 = gPlayerEntity.base.palette.b.b0;
switch (super->action) {
case 0:
super->action = 1;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Block Pushed object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Board object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "functions.h"
@@ -64,10 +63,10 @@ void Board_Action1(BoardEntity* this) {
}
void sub_08098BE8(BoardEntity* this) {
if ((gPlayerState.flags & PL_MINISH) && sub_08098C30(this, &gPlayerEntity) && PlayerCanBeMoved() &&
gPlayerEntity.z.HALF.HI == 0) {
if ((gPlayerState.flags & PL_MINISH) && sub_08098C30(this, &gPlayerEntity.base) && PlayerCanBeMoved() &&
gPlayerEntity.base.z.HALF.HI == 0) {
gPlayerState.field_0x14 = 1;
sub_0807AAF8(&gPlayerEntity, this->tile);
sub_0807AAF8(&gPlayerEntity.base, this->tile);
}
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Bollard object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "flags.h"
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Book object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "functions.h"
#include "item.h"
@@ -111,9 +110,9 @@ void Book_Action1(BookEntity* this) {
gPlayerState.queued_action = PLAYER_PUSH;
gPlayerState.flags |= PL_BUSY;
gPlayerEntity.x.HALF.LO = 0;
gPlayerEntity.y.HALF.LO = 0;
gPlayerEntity.direction = gPlayerEntity.animationState << 2;
gPlayerEntity.base.x.HALF.LO = 0;
gPlayerEntity.base.y.HALF.LO = 0;
gPlayerEntity.base.direction = gPlayerEntity.base.animationState << 2;
EnqueueSFX(SFX_10F);
} else {
super->timer = 22;
@@ -220,7 +219,7 @@ void Book_Action5(BookEntity* this) {
}
u32 sub_0809B688(Entity* this) {
u32 ret = EntityInRectRadius(this, &gPlayerEntity, 6, 12);
u32 ret = EntityInRectRadius(this, &gPlayerEntity.base, 6, 12);
if (ret == 1 && gPlayerState.direction != DirectionSouth) {
ret = 0;
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Boss Door object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "object.h"
@@ -106,7 +105,7 @@ void BossDoor_Action3(BossDoorEntity* this) {
if (--super->timer == 0) {
if (super->type < 4) {
sub_08078AC0(0x40, 0, 1);
gPlayerEntity.direction = super->type << 3;
gPlayerEntity.base.direction = super->type << 3;
}
DeleteThisEntity();
}
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Bush object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "object.h"
@@ -61,7 +60,7 @@ void Bush_Init(BushEntity* this) {
super->gustJarTolerance = gUnk_08120588[super->type].unk_1;
super->gustJarFlags = gUnk_08120588[super->type].unk_2;
super->speed = 0x80;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->health = 1;
super->collisionFlags = 7;
super->hitType = 0x6e;
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Button object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -172,7 +171,7 @@ Entity* sub_08081D74(ButtonEntity* this) {
ent = 0;
if (sub_08081E0C(super)) {
if ((gPlayerState.flags & PL_CAPTURED) == 0 && (gPlayerState.flags & PL_MINISH) == 0) {
ent = &gPlayerEntity;
ent = &gPlayerEntity.base;
}
} else {
if (gPlayerState.flags & PL_CLONING) {
@@ -190,7 +189,7 @@ Entity* sub_08081D74(ButtonEntity* this) {
}
u32 sub_08081E0C(Entity* this) {
Entity* tmp = &gPlayerEntity;
Entity* tmp = &gPlayerEntity.base;
if (tmp->z.HALF.HI != 0 || !PlayerCanBeMoved()) {
return 0;
} else {
@@ -290,7 +289,7 @@ bool32 sub_08081F7C(ButtonEntity* this, u32 r7) {
void sub_08081FF8(Entity* this) {
u32 direction;
u32 i;
if (this->child != &gPlayerEntity)
if (this->child != &gPlayerEntity.base)
return;
direction = GetFacingDirection(this->child, this);
sub_080044AE(this->child, 0x200, direction);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Cabin Furniture object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "flags.h"
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Camera Target object
*/
#define NENT_DEPRECATED
#include "common.h"
#include "entity.h"
#include "functions.h"
@@ -151,7 +150,7 @@ void sub_08083A40(Entity* this) {
this->spriteSettings.draw = 1;
this->action = 2;
if (this->child->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (this->child->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
bVar1 = 0;
this->spriteOffsetX = 8;
} else {
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Carlov Object object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Chest Spawner object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "item.h"
#include "object.h"
@@ -114,14 +113,14 @@ void ChestSpawner_Type2Action2(ChestSpawnerEntity* this) {
SetPriorityTimer(30);
switch (super->subAction) {
case 0:
if (EntityInRectRadius(super, &gPlayerEntity, 0x10, 8)) {
if (EntityInRectRadius(super, &gPlayerEntity.base, 0x10, 8)) {
sub_08078AC0(0x10, 0, 0);
gPlayerEntity.direction = 0x10;
gPlayerEntity.base.direction = 0x10;
}
super->subAction = 1;
break;
case 1:
if ((super->type == 5) || (gPlayerEntity.action == PLAYER_NORMAL)) {
if ((super->type == 5) || (gPlayerEntity.base.action == PLAYER_NORMAL)) {
super->subAction = 2;
super->timer = 8;
super->subtimer = 0;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Chuchu Boss Cutscene object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "menu.h"
#include "object.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Chuchu Boss Particle object
*/
#define NENT_DEPRECATED
#include "entity.h"
void ChuchuBossParticle_Init(Entity*);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Chuchu Boss Start Particle object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Cloud object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
#include "structures.h"
@@ -135,7 +134,7 @@ void sub_0809F69C(CloudEntity* this) {
if (--super->timer == 0) {
super->timer = 30;
super->action = 4;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
SoundReq(SFX_SECRET_BIG);
}
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Cracking Ground object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+6 -7
View File
@@ -4,7 +4,6 @@
*
* @brief Crenel Bean Sprout object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "object.h"
@@ -54,7 +53,7 @@ void CrenelBeanSprout_Init(CrenelBeanSproutEntity* this) {
case 0:
if (CheckGlobalFlag(WATERBEAN_OUT)) {
if (CheckGlobalFlag(WATERBEAN_PUT) == 0) {
PositionRelative(&gPlayerEntity, super, 0, 0x10000);
PositionRelative(&gPlayerEntity.base, super, 0, 0x10000);
SetTile(0x4022, 0xdc, super->collisionLayer);
} else {
if (CheckLocalFlag(super->type2) == 0) {
@@ -80,9 +79,9 @@ void CrenelBeanSprout_Init(CrenelBeanSproutEntity* this) {
case 3:
if (CheckGlobalFlag(WATERBEAN_OUT)) {
if (CheckGlobalFlag(WATERBEAN_PUT) == 0) {
super->spritePriority.b0 = gPlayerEntity.spritePriority.b0 - 1;
*(((u8*)&gPlayerEntity) + 0x79) = tmp;
PositionRelative(&gPlayerEntity, super, 0, -0x180000);
super->spritePriority.b0 = gPlayerEntity.base.spritePriority.b0 - 1;
*(((u8*)&gPlayerEntity.base) + 0x79) = tmp;
PositionRelative(&gPlayerEntity.base, super, 0, -0x180000);
} else {
DeleteThisEntity();
}
@@ -166,7 +165,7 @@ void CrenelBeanSprout_Action1(CrenelBeanSproutEntity* this) {
} else {
GetNextFrame(super);
}
tmp = gPlayerEntity.animationState & 6;
tmp = gPlayerEntity.base.animationState & 6;
this->unk_70 = ((super->x.HALF.HI + (s8)gUnk_08123184[tmp]) & -0x10) | 8;
this->unk_72 = ((super->y.HALF.HI + (s8)gUnk_08123184[(tmp) + 1]) & -0x10) | 8;
if (sub_080B1AB4(this->unk_70, this->unk_72, super->collisionLayer) == 0x19) {
@@ -174,7 +173,7 @@ void CrenelBeanSprout_Action1(CrenelBeanSproutEntity* this) {
} else {
gUnk_0200AF00.rActionPlayerState = R_ACTION_NONE;
}
PositionRelative(&gPlayerEntity, super, 0, 0x10000);
PositionRelative(&gPlayerEntity.base, super, 0, 0x10000);
if (GetActTile(super) == 0x19) {
RestorePrevTileEntity(0xdc, super->collisionLayer);
sub_08096A78(this);
-1
View File
@@ -5,7 +5,6 @@
*
* @brief Cucco Minigame object
*/
#define NENT_DEPRECATED
#include "enemy.h"
#include "entity.h"
#include "fileselect.h"
+10 -11
View File
@@ -4,7 +4,6 @@
*
* @brief Cutscene Misc object
*/
#define NENT_DEPRECATED
#include "area.h"
#include "functions.h"
#include "item.h"
@@ -185,7 +184,7 @@ void sub_08094B80(CutsceneMiscObjectEntity* this) {
void sub_08094B94(CutsceneMiscObjectEntity* this) {
Entity* e = CreateObject(CUTSCENE_MISC_OBJECT, 0x22, 0);
if (e != NULL) {
CopyPosition(&gPlayerEntity, e);
CopyPosition(&gPlayerEntity.base, e);
e->z.HALF.HI = -48;
((CutsceneMiscObjectEntity*)e)->ctx = StartCutscene(e, &script_CutsceneMiscObjectTheLittleHat);
CreateDust(e);
@@ -197,7 +196,7 @@ void sub_08094B94(CutsceneMiscObjectEntity* this) {
void sub_08094BE0(Entity* this) {
Entity* e = FindEntity(OBJECT, CUTSCENE_MISC_OBJECT, 6, 0x22, 0);
if (e != NULL) {
CopyPosition(&gPlayerEntity, e);
CopyPosition(&gPlayerEntity.base, e);
e->z.HALF.HI = -12;
e->y.HALF.HI++;
e->collisionLayer = 2;
@@ -413,7 +412,7 @@ void CutsceneMiscObject_Type6(CutsceneMiscObjectEntity* this) {
}
break;
case 3:
if (gPlayerEntity.action != PLAYER_EMPTYBOTTLE) {
if (gPlayerEntity.base.action != PLAYER_EMPTYBOTTLE) {
super->action = 4;
#ifndef EU
if (!CheckGlobalFlag(BIN_DOGFOOD)) {
@@ -1052,7 +1051,7 @@ void sub_08095D30(CutsceneMiscObjectEntity* this, u32 a2) {
void sub_08095D54(CutsceneMiscObjectEntity* this, ScriptExecutionContext* ctx) {
Entity* e = CreateObject(CUTSCENE_MISC_OBJECT, 0x1C, 0);
if (e != NULL) {
CopyPosition(&gPlayerEntity, e);
CopyPosition(&gPlayerEntity.base, e);
e->collisionLayer = 2;
((CutsceneMiscObjectEntity*)e)->ctx = StartCutscene(e, (u16*)ctx->intVariable);
}
@@ -1153,7 +1152,7 @@ void CutsceneMiscObject_Type31(CutsceneMiscObjectEntity* this) {
break;
}
ChangeObjPalette(super, pal);
if ((gPlayerEntity.frame & 1) == 0) {
if ((gPlayerEntity.base.frame & 1) == 0) {
local->anim = 0x8BF;
super->timer = 52;
super->subtimer = -75;
@@ -1162,16 +1161,16 @@ void CutsceneMiscObject_Type31(CutsceneMiscObjectEntity* this) {
super->timer = 85;
super->subtimer = -42;
}
CopyPosition(&gPlayerEntity, super);
CopyPosition(&gPlayerEntity.base, super);
super->spritePriority.b0 = 3;
}
if (gPlayerEntity.frame & 0x10) {
gPlayerEntity.frame &= ~0x10;
if (gPlayerEntity.base.frame & 0x10) {
gPlayerEntity.base.frame &= ~0x10;
SoundReq(468);
}
if ((u16)gPlayerEntity.spriteIndex != local->anim >> 8 || gPlayerEntity.animIndex != (u8)local->anim)
if ((u16)gPlayerEntity.base.spriteIndex != local->anim >> 8 || gPlayerEntity.base.animIndex != (u8)local->anim)
DeleteThisEntity();
tmp = gPlayerEntity.frameIndex - super->timer + super->subtimer;
tmp = gPlayerEntity.base.frameIndex - super->timer + super->subtimer;
if (tmp != super->frameIndex) {
super->frameIndex = tmp;
sub_080042D0(super, super->frameIndex, (u16)super->spriteIndex);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Cutscene Orchestrator object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "hitbox.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Death Fx object
*/
#define NENT_DEPRECATED
#include "object/deathFx.h"
#include "enemy.h"
#include "entity.h"
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Dirt Particle object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -91,7 +90,7 @@ void DirtParticle_Init(DirtParticleEntity* this) {
}
super->x.HALF.HI += tmp;
super->y.HALF.HI += tmp;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
InitializeAnimation(super, 10);
return;
case 1:
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Double Bookshelf object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -146,7 +145,7 @@ void sub_0809B234(DoubleBookshelfEntity* this) {
}
void sub_0809B274(DoubleBookshelfEntity* this) {
Entity* player = &gPlayerEntity;
Entity* player = &gPlayerEntity.base;
switch (this->unk_84) {
case 0:
if (player->y.HALF.HI + 0x14 >= super->y.HALF.HI) {
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Elements Background object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "screen.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Enemy Item object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+5 -5
View File
@@ -1,4 +1,3 @@
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "flags.h"
@@ -87,7 +86,8 @@ void EvilSpirit_Action1(EvilSpiritEntity* this) {
sub_080045DA(super->parent->x.WORD - super->x.WORD, super->parent->y.WORD - super->y.WORD) ^ 0x80;
} else {
super->speed = 0x600;
dir = sub_080045DA(gPlayerEntity.x.WORD - super->x.WORD, gPlayerEntity.y.WORD - super->y.WORD) ^ 0x80;
dir = sub_080045DA(gPlayerEntity.base.x.WORD - super->x.WORD, gPlayerEntity.base.y.WORD - super->y.WORD) ^
0x80;
if (dir != super->direction) {
if ((u8)(dir - super->direction) > 0x80) {
super->direction += 3;
@@ -95,7 +95,7 @@ void EvilSpirit_Action1(EvilSpiritEntity* this) {
super->direction -= 3;
}
}
if ((gPlayerEntity.animationState & 2) == 0) {
if ((gPlayerEntity.base.animationState & 2) == 0) {
this->unk76 = this->unk7c + 0x40;
} else {
this->unk76 = this->unk7c - 0x20;
@@ -113,7 +113,7 @@ void EvilSpirit_Action1(EvilSpiritEntity* this) {
super->direction++;
super->gustJarTolerance--;
this->unk7f = 1;
if ((gPlayerEntity.animationState & 2) == 0) {
if ((gPlayerEntity.base.animationState & 2) == 0) {
this->unk76 = this->unk7c + 0x10;
} else {
this->unk76 = this->unk7c - 0x20;
@@ -184,7 +184,7 @@ void EvilSpirit_Action3(EvilSpiritEntity* this) {
super->gustJarTolerance--;
this->unk7f = 1;
if ((gPlayerEntity.animationState & 2) == 0) {
if ((gPlayerEntity.base.animationState & 2) == 0) {
this->unk76 = this->unk7c + 0x10;
} else {
this->unk76 = this->unk7c - 0x20;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief EyeSwitch object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "hitbox.h"
+9 -10
View File
@@ -4,7 +4,6 @@
*
* @brief Ezlo Cap object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "message.h"
#include "object.h"
@@ -56,12 +55,12 @@ void EzloCap(EzloCapEntity* this) {
void EzloCap_Type0Init(EzloCapEntity* this) {
super->updatePriority = 6;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
super->spritePriority.b0 = gPlayerEntity.spritePriority.b0 - 1;
super->palette.b.b0 = gPlayerEntity.palette.b.b0;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
super->spritePriority.b0 = gPlayerEntity.base.spritePriority.b0 - 1;
super->palette.b.b0 = gPlayerEntity.base.palette.b.b0;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->action = 1;
if (gPlayerEntity.animationState == 2) {
if (gPlayerEntity.base.animationState == 2) {
super->spriteSettings.flipX = 1;
}
LoadSwapGFX(super, 1, 3);
@@ -79,7 +78,7 @@ void EzloCap_Type0Init(EzloCapEntity* this) {
void EzloCap_Type0Action1(EzloCapEntity* this) {
static const u8 gUnk_0811F16C[] = { 4, 0, 2, 6, 10, 8, 9, 5, 1, 0, 0, 0 };
u32 tmp = gPlayerEntity.palette.b.b0;
u32 tmp = gPlayerEntity.base.palette.b.b0;
super->palette.b.b0 = tmp;
if ((gMessage.state & MESSAGE_ACTIVE) == 0) {
DeleteEntity(super);
@@ -161,8 +160,8 @@ void EzloCap_Type1Action1(EzloCapEntity* this) {
void EzloCap_ScriptedInit(EzloCapEntity* this) {
super->updatePriority = 2;
super->palette.b.b0 = gPlayerEntity.palette.b.b0;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->palette.b.b0 = gPlayerEntity.base.palette.b.b0;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->spritePriority.b1 = 3;
super->spriteSettings.shadow = 1;
super->action = 1;
@@ -171,7 +170,7 @@ void EzloCap_ScriptedInit(EzloCapEntity* this) {
this->unk_82 = 0;
ExecuteScript(super, this->unk_84);
sub_08082D20(this, this->unk_84);
if (gPlayerEntity.animationState == 2) {
if (gPlayerEntity.base.animationState == 2) {
super->spriteSettings.flipX = 1;
}
sub_08082C5C(this);
+16 -18
View File
@@ -4,9 +4,7 @@
*
* @brief Ezlo Cap Flying object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "new_player.h"
#include "object.h"
typedef struct {
@@ -32,7 +30,7 @@ void EzloCapFlying(EzloCapFlyingEntity* this) {
};
if ((gPlayerState.flags & PL_PARACHUTE) == 0) {
if (super->type == 0) {
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
}
DeleteThisEntity();
}
@@ -42,7 +40,7 @@ void EzloCapFlying(EzloCapFlyingEntity* this) {
void EzloCapFlying_Init(EzloCapFlyingEntity* this) {
super->action = 1;
super->lastFrameIndex = 0xff;
super->palette.b.b0 = gPlayerEntity.palette.b.b0;
super->palette.b.b0 = gPlayerEntity.base.palette.b.b0;
if (super->type == 0) {
gRoomControls.camera_target = super;
super->spriteRendering.b0 = 3;
@@ -66,7 +64,7 @@ void EzloCapFlying_Action1Type0(EzloCapFlyingEntity* this) {
if ((s16)this->unk_6e < 0) {
this->unk_6e = -this->unk_6e;
}
switch (gPlayerEntity.subAction) {
switch (gPlayerEntity.base.subAction) {
case 1:
this->unk_72 -= 4;
break;
@@ -104,10 +102,10 @@ void EzloCapFlying_Action1Type0(EzloCapFlyingEntity* this) {
sub_080936C8(this);
break;
}
tmp = gPlayerEntity.animationState & 2;
tmp = gPlayerEntity.base.animationState & 2;
if (tmp != 0) {
super->frameIndex = 1;
if (gPlayerEntity.animationState == 2) {
if (gPlayerEntity.base.animationState == 2) {
this->unk_6e = -this->unk_6e;
}
} else {
@@ -117,32 +115,32 @@ void EzloCapFlying_Action1Type0(EzloCapFlyingEntity* this) {
super->lastFrameIndex = super->frameIndex;
sub_080042D0(super, super->frameIndex, super->spriteIndex);
}
CopyPosition(&gPlayerEntity, super);
CopyPosition(&gPlayerEntity.base, super);
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
sub_0806FCF4(super, this->unk_72, 10, 2);
SetAffineInfo(super, this->unk_6e, this->unk_72, 0);
sub_0806FEBC(&gPlayerEntity, 1, super);
sub_0806FEBC(&gPlayerEntity.base, 1, super);
}
void EzloCapFlying_Action1Type1(EzloCapFlyingEntity* this) {
super->frameIndex = ((gPlayerEntity.direction + (gPlayerEntity.direction >> 1)) >> 2) + 2;
super->frameIndex = ((gPlayerEntity.base.direction + (gPlayerEntity.base.direction >> 1)) >> 2) + 2;
if (super->frameIndex != super->lastFrameIndex) {
super->lastFrameIndex = super->frameIndex;
sub_080042D0(super, super->frameIndex, super->spriteIndex);
}
CopyPosition(&gPlayerEntity, super);
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
CopyPosition(&gPlayerEntity.base, super);
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
sub_0806FCF4(super, ((EzloCapFlyingEntity*)super->parent)->unk_72, 0x18, 0);
super->spriteOffsetY = -super->spriteOffsetY;
sub_0806FEBC(&gPlayerEntity, 0, super);
sub_0806FEBC(&gPlayerEntity.base, 0, super);
}
void sub_080936C8(EzloCapFlyingEntity* this) {
s32 tmp = gNewPlayerEntity.unk_7c;
this->unk_76 = 0x138 - (gNewPlayerEntity.unk_7c >> 2);
s32 tmp = gPlayerEntity.unk_7c.WORD_U;
this->unk_76 = 0x138 - (gPlayerEntity.unk_7c.WORD_U >> 2);
this->unk_74 = 8 - (tmp / 0x3c);
if (super->timer == 0) {
if (this->unk_76 < this->unk_6e) {
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Fairy object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "functions.h"
#include "hitbox.h"
@@ -182,7 +181,7 @@ void Fairy_Action3(FairyEntity* this) {
} else {
CopyPosition(super->child, super);
super->z.HALF.HI--;
if (IsColliding(super, &gPlayerEntity)) {
if (IsColliding(super, &gPlayerEntity.base)) {
sub_0808DB2C(this);
}
}
@@ -246,8 +245,8 @@ void sub_0808DAD0(FairyEntity* this) {
super->spriteSettings.draw = 1;
super->spritePriority.b1 = 2;
super->spriteOffsetY = -5;
super->child = &gPlayerEntity;
CopyPosition(&gPlayerEntity, super);
super->child = &gPlayerEntity.base;
CopyPosition(&gPlayerEntity.base, super);
}
void sub_0808DB2C(FairyEntity* this) {
@@ -255,5 +254,5 @@ void sub_0808DB2C(FairyEntity* this) {
super->subAction = 0;
super->flags |= ENT_COLLIDE;
super->flags2 = 1;
CopyPosition(&gPlayerEntity, super);
CopyPosition(&gPlayerEntity.base, super);
}
+3 -4
View File
@@ -4,7 +4,6 @@
*
* @brief Fan object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "entity.h"
#include "flags.h"
@@ -115,7 +114,7 @@ void sub_0809EE44(FanEntity* this) {
uVar4 = (super->frame & 7);
super->speed = this->unk7e << uVar4;
if (uVar4 != 0) {
pEVar1 = &gPlayerEntity;
pEVar1 = &gPlayerEntity.base;
if (sub_0809EF78(this, pEVar1)) {
if (PlayerCanBeMoved()) {
sub_08079E58(super->speed, super->direction);
@@ -136,8 +135,8 @@ void sub_0809EE44(FanEntity* this) {
bVar3 = 1;
break;
case 0x3:
if (pEVar1->x.HALF.HI != gPlayerEntity.x.HALF.HI ||
pEVar1->y.HALF.HI != gPlayerEntity.y.HALF.HI)
if (pEVar1->x.HALF.HI != gPlayerEntity.base.x.HALF.HI ||
pEVar1->y.HALF.HI != gPlayerEntity.base.y.HALF.HI)
bVar3 = 1;
break;
break;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Fan Wind object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "entity.h"
#include "functions.h"
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Figurine Device object
*/
#define NENT_DEPRECATED
#include "figurineMenu.h"
#include "fileselect.h"
#include "functions.h"
@@ -718,7 +717,7 @@ void FigurineDevice_NoFigurinesLeftMessage(void) {
gMessage.rupees = 5;
}
#ifndef EU
gPlayerEntity.animationState = 6;
gPlayerEntity.base.animationState = 6;
#endif
}
@@ -795,9 +794,9 @@ void sub_0808861C(FigurineDeviceEntity* this, ScriptExecutionContext* context) {
// If I understand this correctly then it checks if the player is at the lever
context->condition = CheckPlayerInRegion(168, 84, 12, 8);
#ifdef JP
if ((gPlayerEntity.animationState != 0)) {
if ((gPlayerEntity.base.animationState != 0)) {
#else
if ((gPlayerEntity.animationState != 0) || (gPlayerEntity.z.HALF.HI != 0)) {
if ((gPlayerEntity.base.animationState != 0) || (gPlayerEntity.base.z.HALF.HI != 0)) {
#endif
context->condition = 0;
}
@@ -807,7 +806,7 @@ void sub_0808861C(FigurineDeviceEntity* this, ScriptExecutionContext* context) {
#if !defined(JP)
void sub_08088658(FigurineDeviceEntity* this, ScriptExecutionContext* context) {
context->condition = CheckPlayerInRegion(120, 120, 16, 8); // And this is if the player is at the door
if (gPlayerEntity.z.HALF.HI != 0) {
if (gPlayerEntity.base.z.HALF.HI != 0) {
context->condition = 0;
}
gActiveScriptInfo.flags |= 1;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief File Screen Objects object
*/
#define NENT_DEPRECATED
#include "fileselect.h"
#include "functions.h"
#include "main.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Fireball Chain object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "global.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Fireplace object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Flame object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "functions.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Floating Block object
*/
#define NENT_DEPRECATED
#include "object.h"
void FloatingBlock(Entity* this) {
+2 -3
View File
@@ -4,7 +4,6 @@
*
* @brief Floating Platform object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "object.h"
@@ -64,9 +63,9 @@ bool32 sub_08086168(FloatingPlatformEntity* this) {
const u8* ptr;
ptr = gUnk_08120658 + super->type * 2;
if (((EntityInRectRadius(super, &gPlayerEntity, ptr[0], ptr[1])) && PlayerCanBeMoved())) {
if (((EntityInRectRadius(super, &gPlayerEntity.base, ptr[0], ptr[1])) && PlayerCanBeMoved())) {
gPlayerState.field_0x14 = 1;
if (gPlayerEntity.z.HALF.HI == 0) {
if (gPlayerEntity.base.z.HALF.HI == 0) {
return TRUE;
} else {
return FALSE;
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Four Elements object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "functions.h"
#include "hitbox.h"
@@ -108,7 +107,7 @@ void FourElements_Action3(FourElementsEntity* this) {
if (super->timer != 0) {
sub_080A0424(this);
if (--super->timer == 0) {
SetEntityPriority(&gPlayerEntity, 0);
SetEntityPriority(&gPlayerEntity.base, 0);
}
} else {
RequestPriorityDuration(NULL, 60);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Frozen Flower object
*/
#define NENT_DEPRECATED
#include "object.h"
void FrozenFlower_Init(Entity*);
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Frozen Octorok object
*/
#define NENT_DEPRECATED
#include "enemy/octorokBoss.h"
#include "functions.h"
#include "message.h"
@@ -387,7 +386,7 @@ void FrozenOctorok_Action1SubAction6(FrozenOctorokEntity* this) {
LinearMoveUpdate(super);
if ((gRoomControls.origin_y + 0x1c8) < super->y.HALF.HI) {
gRoomControls.scrollSpeed = 4;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
SetLocalFlag(0x9b);
DeleteEntity(super->parent);
DeleteEntity(&this->heap->mouthObject->base);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Frozen Water Element object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+6 -6
View File
@@ -4,7 +4,6 @@
*
* @brief Furniture object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "object.h"
@@ -310,7 +309,8 @@ static void FurnitureInit(FurnitureEntity* this) {
static void FurnitureUpdate(FurnitureEntity* this) {
switch (this->flags & 0x7FFF) {
case 0x1:
if (gPlayerEntity.y.HALF.HI < super->y.HALF.HI || gPlayerEntity.y.HALF.HI > super->y.HALF.HI + 24) {
if (gPlayerEntity.base.y.HALF.HI < super->y.HALF.HI ||
gPlayerEntity.base.y.HALF.HI > super->y.HALF.HI + 24) {
super->spriteRendering.b3 = 2;
} else {
super->spriteRendering.b3 = 3;
@@ -338,16 +338,16 @@ static void FurnitureUpdate(FurnitureEntity* this) {
}
break;
case 0x80:
if (gPlayerEntity.y.HALF.HI < super->y.HALF.HI + 8) {
if (gPlayerEntity.base.y.HALF.HI < super->y.HALF.HI + 8) {
if (gPlayerState.floor_type != SURFACE_LADDER && GetTileTypeByEntity(super) == 0x4017) {
SetTile(0x4026, this->tile, super->collisionLayer);
SetTile(0x403D, this->tile - 64, super->collisionLayer);
SetTile(0x403D, this->tile - 128, super->collisionLayer);
}
} else {
if (gPlayerEntity.collisionLayer & 2) {
gPlayerEntity.collisionLayer = 1;
UpdateSpriteForCollisionLayer(&gPlayerEntity);
if (gPlayerEntity.base.collisionLayer & 2) {
gPlayerEntity.base.collisionLayer = 1;
UpdateSpriteForCollisionLayer(&gPlayerEntity.base);
}
if (GetTileTypeByEntity(super) != 0x4017) {
SetTile(0x4017, this->tile, super->collisionLayer);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Gentari Curtain object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "flags.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Giant Book Ladder object
*/
#define NENT_DEPRECATED
#include "object.h"
#include "manager.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Giant Leaf object
*/
#define NENT_DEPRECATED
#include "object.h"
void sub_0808D618(Entity* this);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Giant Rock object
*/
#define NENT_DEPRECATED
#include "entity.h"
void GiantRock(Entity* this) {
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Giant Rock 2 object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "room.h"
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Giant Twig object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -103,7 +102,7 @@ void GiantTwig_Type0Init(GiantTwigEntity* this) {
void GiantTwig_Type0Idle(GiantTwigEntity* this) {
if (super->type == 0) {
if (gPlayerEntity.y.HALF.HI < super->y.HALF.HI + 0x20) {
if (gPlayerEntity.base.y.HALF.HI < super->y.HALF.HI + 0x20) {
super->spriteRendering.b3 = 1;
} else {
super->spriteRendering.b3 = 2;
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Gleerok Particle object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "effects.h"
#include "entity.h"
@@ -78,7 +77,7 @@ void GleerokParticle_Init(GleerokParticleEntity* this) {
gRoomControls.camera_target = super;
} else {
if (--this->unk78 == -1) {
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
DeleteThisEntity();
}
}
+6 -6
View File
@@ -4,7 +4,6 @@
*
* @brief Graveyard Key object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "collision.h"
#include "effects.h"
@@ -93,7 +92,7 @@ void GraveyardKey_Init(Entity* this, const struct_gUnk_08123FB0* param_2) {
if ((this->direction & DIR_NOT_MOVING_CHECK)) {
dir = this->direction;
if (dir == (DIR_NOT_MOVING_CHECK | 0x1)) {
this->direction = (((gPlayerEntity.animationState * 4 + (Random() & 3)) - 2) & 0x1f) ^ DirectionSouth;
this->direction = (((gPlayerEntity.base.animationState * 4 + (Random() & 3)) - 2) & 0x1f) ^ DirectionSouth;
}
}
UpdateSpriteForCollisionLayer(this);
@@ -131,7 +130,7 @@ void GraveyardKey_Action2(Entity* this, const struct_gUnk_08123FB0* param_2) {
this->zVelocity = param_2->unk14 << 3;
} else {
this->action++;
this->collisionLayer = gPlayerEntity.collisionLayer;
this->collisionLayer = gPlayerEntity.base.collisionLayer;
UpdateSpriteForCollisionLayer(this);
if (param_2->funcEnt != NULL) {
param_2->funcEnt(this);
@@ -178,13 +177,14 @@ void sub_0809D91C(Entity* this) {
bool32 sub_0809D93C(Entity* this, const struct_gUnk_08123FB0* param_2) {
u32 uVar1;
if (gPlayerEntity.action == PLAYER_BOUNCE && ((param_2->unk0c >> gPlayerEntity.animationState & 1) != 0)) {
uVar1 = (gPlayerEntity.x.HALF.HI - this->x.HALF.HI) + param_2->unk08 + param_2->unk0a;
if (gPlayerEntity.base.action == PLAYER_BOUNCE &&
((param_2->unk0c >> gPlayerEntity.base.animationState & 1) != 0)) {
uVar1 = (gPlayerEntity.base.x.HALF.HI - this->x.HALF.HI) + param_2->unk08 + param_2->unk0a;
if (param_2->unk0a * 2 <= (u16)uVar1) {
return 0;
}
uVar1 = (gPlayerEntity.y.HALF.HI - (this->y.HALF.HI + param_2->y)) + param_2->unk09 + param_2->unk0b;
uVar1 = (gPlayerEntity.base.y.HALF.HI - (this->y.HALF.HI + param_2->y)) + param_2->unk09 + param_2->unk0b;
if (param_2->unk0b * 2 > (u16)uVar1) {
return 1;
}
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Great Fairy object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
#include "save.h"
@@ -66,12 +65,12 @@ void GreatFairy(GreatFairyEntity* this) {
void GreatFairy_CallBehavior(GreatFairyEntity* this) {
GreatFairy_Behaviors[super->action](this);
if ((gPlayerEntity.y.HALF.HI - gRoomControls.origin_y) < 168) {
if ((gPlayerEntity.base.y.HALF.HI - gRoomControls.origin_y) < 168) {
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 2;
} else {
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
gRoomControls.scrollSpeed = 2;
}
}
@@ -542,8 +541,8 @@ void sub_08087424(GreatFairyEntity* this, ScriptExecutionContext* context) {
ResetPlayerAnimationAndAction();
ent = CreateObject(THUNDERBOLT, 0, 0);
if (ent != NULL) {
ent->parent = &gPlayerEntity;
CopyPosition(&gPlayerEntity, ent);
ent->parent = &gPlayerEntity.base;
CopyPosition(&gPlayerEntity.base, ent);
SetEntityPriority(ent, PRIO_MESSAGE);
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Guruguru Bar object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "object.h"
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Gust Jar Particle object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "physics.h"
@@ -26,10 +25,10 @@ void GustJarParticle(Entity* this) {
void GustJarParticle_Init(Entity* this) {
this->action = 1;
this->speed = 0x80;
this->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
this->spritePriority.b0 = gPlayerEntity.spritePriority.b0;
this->collisionLayer = gPlayerEntity.collisionLayer;
this->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
this->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
this->spritePriority.b0 = gPlayerEntity.base.spritePriority.b0;
this->collisionLayer = gPlayerEntity.base.collisionLayer;
this->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
this->type = Random() & 1;
InitializeAnimation(this, 0x11);
}
+4 -5
View File
@@ -4,7 +4,6 @@
*
* @brief Gyorg Boss object
*/
#define NENT_DEPRECATED
#include "area.h"
#include "enemy/gyorg.h"
#include "entity.h"
@@ -229,7 +228,7 @@ void GyorgBossObject_FemalePhase4(GyorgBossObjectEntity* this) {
}
this->unk_6c = 0;
gRoomTransition.field_0x39 = 0;
if (PlayerCanBeMoved() && gPlayerEntity.z.HALF.HI == 0) {
if (PlayerCanBeMoved() && gPlayerEntity.base.z.HALF.HI == 0) {
super->action = 9;
super->timer = 0;
super->subtimer = 240;
@@ -237,7 +236,7 @@ void GyorgBossObject_FemalePhase4(GyorgBossObjectEntity* this) {
super->direction = 0;
super->speed = 0x60;
gPlayerState.flags &= ~PL_GYORG_FIGHT;
CopyPosition(&gPlayerEntity, super);
CopyPosition(&gPlayerEntity.base, super);
gRoomControls.camera_target = super;
SetPlayerControl(2);
}
@@ -464,7 +463,7 @@ void sub_080A1FF0(GyorgBossObjectEntity* this) {
}
}
if (this->unk_7b) {
if (EntityWithinDistance(&gPlayerEntity, gRoomControls.origin_x + 0x200, gRoomControls.origin_y + 0x210,
if (EntityWithinDistance(&gPlayerEntity.base, gRoomControls.origin_x + 0x200, gRoomControls.origin_y + 0x210,
0x100)) {
if (super->timer == 0) {
super->timer = 120;
@@ -483,7 +482,7 @@ u32 sub_080A20B8(GyorgBossObjectEntity* this, GyorgMaleEntity* other) {
if (other == NULL) {
return 1;
}
if (PlayerCanBeMoved() && gPlayerEntity.z.HALF.HI == 0) {
if (PlayerCanBeMoved() && gPlayerEntity.base.z.HALF.HI == 0) {
return other->unk_7c == 0 && gPlayerState.field_0x14 != 0;
}
return 0;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief HeartContainer object
*/
#define NENT_DEPRECATED
#include "collision.h"
#include "entity.h"
#include "flags.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Hidden Ladder Down object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "flags.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Hit Switch object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "physics.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Hittable Lever object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief House Door Exterior object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "functions.h"
@@ -183,7 +182,7 @@ void sub_0808692C(HouseDoorExteriorEntity* this) {
static u8 sub_08086954(HouseDoorExteriorEntity* this) {
if (sub_0800445C(super)) {
if (GetAnimationStateInRectRadius(super, 6, 20) >= 0 && gPlayerEntity.animationState == 0 &&
if (GetAnimationStateInRectRadius(super, 6, 20) >= 0 && gPlayerEntity.base.animationState == 0 &&
(u16)gPlayerState.playerInput.heldInput == INPUT_UP && gPlayerState.jump_status == 0) {
super->timer--;
}
+2 -2
View File
@@ -4,7 +4,6 @@
*
* @brief House Door Interior object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "functions.h"
@@ -92,7 +91,8 @@ void HouseDoorInterior_Action1(HouseDoorInteriorEntity* this) {
if (sub_0800445C(super) && this->unk7d == 0) {
ptr = gUnk_081227CC + super->type2;
if (GetAnimationStateInRectRadius(super, ptr->x, ptr->y) >= 0 &&
ptr->animationState == gPlayerEntity.animationState && gPlayerState.playerInput.heldInput & ptr->unk2) {
ptr->animationState == gPlayerEntity.base.animationState &&
gPlayerState.playerInput.heldInput & ptr->unk2) {
--super->timer;
}
} else {
+2 -9
View File
@@ -4,16 +4,9 @@
*
* @brief HouseSign object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "object/houseSign.h"
typedef struct {
/*0x00*/ Entity base;
/*0x68*/ u8 unused1[24];
/*0x80*/ s16 unk_80;
/*0x82*/ s16 unk_82;
} HouseSignEntity;
#include "asm.h"
/*
This object is created by HouseSignManager.
+7 -15
View File
@@ -4,20 +4,12 @@
*
* @brief Item for Sale object
*/
#define NENT_DEPRECATED
#include "object/itemForSale.h"
#include "functions.h"
#include "hitbox.h"
#include "kinstone.h"
#include "message.h"
#include "new_player.h"
#include "object.h"
typedef struct {
/*0x00*/ Entity base;
/*0x68*/ u8 unk_68[0x18];
/*0x80*/ u16 unk_80;
/*0x82*/ u16 unk_82;
} ItemForSaleEntity;
typedef struct {
u8 before[0x20];
@@ -99,7 +91,7 @@ void ItemForSale_Action1(ItemForSaleEntity* this) {
PausePlayer();
ResetActiveItems();
gPlayerState.heldObject = 4;
gNewPlayerEntity.unk_74 = super;
gPlayerEntity.unk_74 = super;
gUnk_0200AF00.rActionPlayerState = R_ACTION_DROP;
MessageClose();
}
@@ -111,8 +103,8 @@ void ItemForSale_Action2(ItemForSaleEntity* this) {
void* ptr;
gUnk_0200AF00.rActionPlayerState = R_ACTION_DROP;
super->spriteSettings.draw = gPlayerEntity.spriteSettings.draw;
if ((gPlayerState.heldObject == 0) || (super != gNewPlayerEntity.unk_74)) {
super->spriteSettings.draw = gPlayerEntity.base.spriteSettings.draw;
if ((gPlayerState.heldObject == 0) || (super != gPlayerEntity.unk_74)) {
sub_080819B4(this);
} else {
ptr = sub_080784E4();
@@ -137,7 +129,7 @@ void sub_080819B4(ItemForSaleEntity* this) {
DeleteThisEntity();
}
gPlayerState.heldObject = 0;
gNewPlayerEntity.unk_74 = 0;
gPlayerEntity.unk_74 = 0;
ptr = &gUnk_0200AF00;
gRoomVars.shopItemType = 0;
ptr->rActionInteractObject = R_ACTION_NONE;
@@ -148,7 +140,7 @@ void sub_080819B4(ItemForSaleEntity* this) {
super->z.WORD = 0;
super->action = 1;
super->subAction = 0;
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
super->collisionLayer = 1;
super->spritePriority.b0 = 4;
UpdateSpriteForCollisionLayer(super);
+5 -6
View File
@@ -4,7 +4,6 @@
*
* @brief Item On Ground object
*/
#define NENT_DEPRECATED
#include "object/itemOnGround.h"
#include "collision.h"
#include "entity.h"
@@ -188,7 +187,7 @@ void sub_080810FC(ItemOnGroundEntity* this) {
super->subAction = 0;
COLLISION_ON(super);
super->flags2 = 0x11;
CopyPosition(&gPlayerEntity, super);
CopyPosition(&gPlayerEntity.base, super);
}
}
@@ -296,10 +295,10 @@ void sub_080812A8(ItemOnGroundEntity* this) {
void sub_080812E8(ItemOnGroundEntity* this) {
PlayerState* playerState = &gPlayerState;
#ifdef EU
if ((playerState->swim_state & 0x80) && IsColliding(super, &gPlayerEntity)) {
if ((playerState->swim_state & 0x80) && IsColliding(super, &gPlayerEntity.base)) {
#else
if ((playerState->swim_state & 0x80) && (playerState->flags & PL_MINISH) == 0 &&
IsColliding(super, &gPlayerEntity)) {
IsColliding(super, &gPlayerEntity.base)) {
#endif
sub_080810FC(this);
}
@@ -315,7 +314,7 @@ void ItemOnGround_Action3(ItemOnGroundEntity* this) {
} else {
CopyPosition(other, super);
super->z.HALF.HI--;
other = &gPlayerEntity;
other = &gPlayerEntity.base;
if (IsColliding(super, other)) {
sub_080810FC(this);
}
@@ -482,7 +481,7 @@ void sub_08081598(ItemOnGroundEntity* this) {
super->spriteSettings.draw = 1;
super->spritePriority.b1 = 2;
super->spritePriority.b0 = 3;
super->child = &gPlayerEntity;
super->child = &gPlayerEntity.base;
CopyPosition(super->child, super);
super->z.HALF.HI -= 4;
if (super->type != 0x5F && sub_08081420(this)) {
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Jail Bars object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "flags.h"
#include "functions.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Japanese Subtitle object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "menu.h"
#include "object.h"
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Jar Portal object
*/
#define NENT_DEPRECATED
#include "area.h"
#include "functions.h"
#include "object.h"
+8 -8
View File
@@ -4,7 +4,6 @@
*
* @brief Key Stealing Takkuri object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -170,7 +169,7 @@ void KeyStealingTakkuri_Type5_Action1(KeyStealingTakkuriEntity* this) {
super->zVelocity = Q_16_16(1.0);
} else {
super->action++;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
UpdateSpriteForCollisionLayer(super);
}
SoundReq(SFX_RUPEE_BOUNCE);
@@ -393,7 +392,7 @@ void sub_0809E0A0(KeyStealingTakkuriEntity* this) {
obj->parent = super;
super->child = obj;
super->subtimer = 0;
CopyPosition(&gPlayerEntity, obj);
CopyPosition(&gPlayerEntity.base, obj);
obj->z.HALF.HI = -8;
}
}
@@ -415,7 +414,7 @@ void sub_0809E0D4(KeyStealingTakkuriEntity* this, ScriptExecutionContext* contex
return;
}
} else {
entity = &gPlayerEntity;
entity = &gPlayerEntity.base;
}
context->unk_18++;
sub_0807DEDC(super, context, entity->x.HALF.HI, entity->y.HALF.HI);
@@ -476,7 +475,8 @@ void sub_0809E1F0(KeyStealingTakkuriEntity* this) {
}
void sub_0809E210(KeyStealingTakkuriEntity* this) {
gPlayerEntity.animationState = GetAnimationStateForDirection8(GetFacingDirection(&gPlayerEntity, super)) & 0xfe;
gPlayerEntity.base.animationState =
GetAnimationStateForDirection8(GetFacingDirection(&gPlayerEntity.base, super)) & 0xfe;
gPlayerState.animation = ANIM_DEFAULT;
}
@@ -505,8 +505,8 @@ u32 sub_0809E2C4(KeyStealingTakkuriEntity* this, u32 param_2) {
s32 roomY;
ptr = &gUnk_08124178[param_2 * 2];
roomX = gPlayerEntity.x.HALF.HI - (gRoomControls.origin_x + ptr[0]);
roomY = gPlayerEntity.y.HALF.HI - (gRoomControls.origin_y + ptr[1]);
roomX = gPlayerEntity.base.x.HALF.HI - (gRoomControls.origin_x + ptr[0]);
roomY = gPlayerEntity.base.y.HALF.HI - (gRoomControls.origin_y + ptr[1]);
tmp = gUnk_08124158;
counter = 0;
while (counter < 4) {
@@ -516,7 +516,7 @@ u32 sub_0809E2C4(KeyStealingTakkuriEntity* this, u32 param_2) {
uVar1 = roomY - tmp->unk_2 + tmp->unk_5;
uVar2 = tmp->unk_5 * 2;
if (uVar2 > (u16)uVar1) {
if (tmp->unk_6 == gPlayerEntity.animationState && gPlayerEntity.action == PLAYER_BOUNCE) {
if (tmp->unk_6 == gPlayerEntity.base.animationState && gPlayerEntity.base.action == PLAYER_BOUNCE) {
return 1;
}
return 2;
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Kinstone Fusion Particle object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "kinstone.h"
#include "object.h"
+5 -6
View File
@@ -4,7 +4,6 @@
*
* @brief Ladder Hole In Bookshelf object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "player.h"
@@ -30,7 +29,7 @@ void LadderHoleInBookshelf_Init(Entity* this) {
void LadderHoleInBookshelf_Action1(Entity* this) {
if (sub_08094064(this)) {
if (this->collisionLayer == 2) {
switch (gPlayerEntity.action) {
switch (gPlayerEntity.base.action) {
case PLAYER_CLIMB:
case PLAYER_USEENTRANCE:
return;
@@ -39,7 +38,7 @@ void LadderHoleInBookshelf_Action1(Entity* this) {
UpdateSpriteForCollisionLayer(this);
this->spritePriority.b0 = 5;
} else {
switch (gPlayerEntity.action) {
switch (gPlayerEntity.base.action) {
case PLAYER_CLIMB:
case PLAYER_USEENTRANCE:
this->collisionLayer = 2;
@@ -47,10 +46,10 @@ void LadderHoleInBookshelf_Action1(Entity* this) {
this->spritePriority.b0 = 1;
break;
default:
if ((gPlayerEntity.collisionLayer & 2) == 0) {
if ((gPlayerEntity.base.collisionLayer & 2) == 0) {
break;
}
gPlayerEntity.collisionLayer = 1;
gPlayerEntity.base.collisionLayer = 1;
break;
}
}
@@ -59,7 +58,7 @@ void LadderHoleInBookshelf_Action1(Entity* this) {
bool32 sub_08094064(Entity* this) {
bool32 rv = 1;
if (gPlayerEntity.x.HALF.HI - this->x.HALF.HI + 0x1cU >= 0x39) {
if (gPlayerEntity.base.x.HALF.HI - this->x.HALF.HI + 0x1cU >= 0x39) {
rv = 0;
}
+1 -2
View File
@@ -4,7 +4,6 @@
*
* @brief Ladder Up object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "effects.h"
#include "entity.h"
@@ -65,7 +64,7 @@ void LadderUp(Entity* this) {
#endif
default:
if (this->type2 == 0) {
if (gPlayerEntity.y.HALF.HI < this->y.HALF.HI) {
if (gPlayerEntity.base.y.HALF.HI < this->y.HALF.HI) {
if (gPlayerState.floor_type != SURFACE_LADDER && (GetTileTypeByEntity(this) == 0x4017)) {
SetTile(0x4023, COORD_TO_TILE(this), this->collisionLayer);
RestorePrevTileEntity(COORD_TO_TILE_OFFSET(this, 0, 0x10), this->collisionLayer);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Lamp object
*/
#define NENT_DEPRECATED
#include "entity.h"
void Lamp_Init(Entity* this);
-1
View File
@@ -4,7 +4,6 @@
*
* @brief LampParticle object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "item.h"
#include "player.h"
+2 -3
View File
@@ -4,7 +4,6 @@
*
* @brief Lava Platform object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "hitbox.h"
#include "object.h"
@@ -279,10 +278,10 @@ void sub_0809264C(LavaPlatformEntity* this) {
}
bool32 LavaPlatform_IsPlayerOnPlatform(LavaPlatformEntity* this) {
if ((gPlayerState.flags & PL_MINISH) == 0 && EntityInRectRadius(super, &gPlayerEntity, 0x10, 0x10) &&
if ((gPlayerState.flags & PL_MINISH) == 0 && EntityInRectRadius(super, &gPlayerEntity.base, 0x10, 0x10) &&
PlayerCanBeMoved()) {
gPlayerState.field_0x14 = 1;
if (gPlayerEntity.z.HALF.HI == 0) {
if (gPlayerEntity.base.z.HALF.HI == 0) {
super->subtimer = 1;
return TRUE;
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Light Door object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
#include "screen.h"
+14 -15
View File
@@ -4,7 +4,6 @@
*
* @brief Light Ray object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
#include "screen.h"
@@ -42,12 +41,12 @@ void LightRay_Type0(LightRayEntity* this) {
super->subtimer = 0;
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 1;
if (super->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (super->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
tmp = 2;
} else {
tmp = 6;
}
gPlayerEntity.animationState = tmp;
gPlayerEntity.base.animationState = tmp;
gScreen.lcd.displayControl = (gScreen.lcd.displayControl & 0xbfff) | 0x2800;
gScreen.controls.window0HorizontalDimensions = 0;
gScreen.controls.window0VerticalDimensions = 0xa0;
@@ -67,7 +66,7 @@ void LightRay_Type0(LightRayEntity* this) {
super->action = 2;
super->timer = 60;
gScreen.lcd.displayControl &= 0xdfff;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
SoundReq(SFX_134);
}
}
@@ -116,12 +115,12 @@ void LightRay_Type1(LightRayEntity* this) {
super->subtimer = 32;
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 1;
if (super->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (super->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
tmp = 2;
} else {
tmp = 6;
}
gPlayerEntity.animationState = tmp;
gPlayerEntity.base.animationState = tmp;
gScreen.lcd.displayControl = (gScreen.lcd.displayControl & 0xbfff) | 0x2000;
gScreen.controls.window0HorizontalDimensions = DISPLAY_WIDTH;
gScreen.controls.window0VerticalDimensions = DISPLAY_HEIGHT;
@@ -140,7 +139,7 @@ void LightRay_Type1(LightRayEntity* this) {
} else {
super->action = 2;
super->timer = 60;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
SoundReq(SFX_134);
}
}
@@ -167,12 +166,12 @@ void LightRay_Type2(LightRayEntity* this) {
super->subtimer = 0;
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 1;
if (super->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (super->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
tmp = 2;
} else {
tmp = 6;
}
gPlayerEntity.animationState = tmp;
gPlayerEntity.base.animationState = tmp;
gScreen.controls.window0HorizontalDimensions = 0x60;
gScreen.controls.window0VerticalDimensions = 0xa0;
break;
@@ -212,7 +211,7 @@ void LightRay_Type2(LightRayEntity* this) {
case 3:
if (--super->timer == 0) {
super->action = 4;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
gRoomControls.scrollSpeed = 2;
}
break;
@@ -237,12 +236,12 @@ void LightRay_Type3(LightRayEntity* this) {
super->subtimer = 0;
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 1;
if (super->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (super->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
tmp = 2;
} else {
tmp = 6;
}
gPlayerEntity.animationState = tmp;
gPlayerEntity.base.animationState = tmp;
gScreen.controls.window0HorizontalDimensions = 0x80f0;
gScreen.controls.window0VerticalDimensions = 0xa0;
super->subAction = 0x80;
@@ -293,12 +292,12 @@ void LightRay_Type4(LightRayEntity* this) {
super->subtimer = 128;
gRoomControls.camera_target = super;
gRoomControls.scrollSpeed = 1;
if (super->x.HALF.HI > gPlayerEntity.x.HALF.HI) {
if (super->x.HALF.HI > gPlayerEntity.base.x.HALF.HI) {
tmp = 2;
} else {
tmp = 6;
}
gPlayerEntity.animationState = tmp;
gPlayerEntity.base.animationState = tmp;
break;
case 1:
if (super->timer != 0) {
@@ -311,7 +310,7 @@ void LightRay_Type4(LightRayEntity* this) {
} else {
super->action = 2;
super->timer = 60;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
SoundReq(SFX_134);
}
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief Lightable Switch object
*/
#define NENT_DEPRECATED
#include "asm.h"
#include "entity.h"
#include "flags.h"
+32 -33
View File
@@ -4,7 +4,6 @@
*
* @brief Large Lilypad object
*/
#define NENT_DEPRECATED
#include "object/lilypadLarge.h"
#include "area.h"
#include "functions.h"
@@ -101,19 +100,19 @@ void LilypadLarge_Action1(LilypadLargeEntity* this) {
u32 uVar4;
super->flags |= 0x20;
if (sub_0806FC80(super, &gPlayerEntity, 0x18) != 0) {
if (sub_0806FC80(super, &gPlayerEntity.base, 0x18) != 0) {
gPlayerState.flags |= PL_FLAGS2;
if (gPlayerEntity.z.WORD == 0) {
if (gPlayerEntity.base.z.WORD == 0) {
if (gPlayerState.swim_state != 0) {
gPlayerEntity.collisionFlags &= 0xfb;
gPlayerEntity.base.collisionFlags &= 0xfb;
gPlayerState.swim_state = 0;
}
gPlayerState.lilypad = super;
if (super->collisionLayer == 1) {
ResetCollisionLayer(&gPlayerEntity);
ResetCollisionLayer(&gPlayerEntity.base);
} else {
sub_08004542(&gPlayerEntity);
sub_08004542(&gPlayerEntity.base);
}
if (super->subtimer == 0) {
super->subtimer = 4;
@@ -128,7 +127,7 @@ void LilypadLarge_Action1(LilypadLargeEntity* this) {
}
if (gPlayerState.field_0x1c == 3) {
tmp = gUnk_08120620[gPlayerState.gustJarSpeed - 1];
switch (gPlayerEntity.animationState & 6) {
switch (gPlayerEntity.base.animationState & 6) {
case 4:
this->unk_70 -= tmp;
break;
@@ -151,8 +150,8 @@ void LilypadLarge_Action1(LilypadLargeEntity* this) {
SoundReq(SFX_WATER_WALK);
}
if ((super->contactFlags & 0x7f) == 0x13) {
sVar10 = gPlayerEntity.x.HALF.HI + gUnk_08126EE4[gPlayerEntity.animationState & 0xe];
uVar4 = gPlayerEntity.y.HALF.HI + gUnk_08126EE4[gPlayerEntity.animationState | 1];
sVar10 = gPlayerEntity.base.x.HALF.HI + gUnk_08126EE4[gPlayerEntity.base.animationState & 0xe];
uVar4 = gPlayerEntity.base.y.HALF.HI + gUnk_08126EE4[gPlayerEntity.base.animationState | 1];
super->direction = CalculateDirectionTo(super->x.HALF.HI, super->y.HALF.HI, sVar10, uVar4);
switch (gPlayerState.gustJarSpeed) {
@@ -378,26 +377,26 @@ void sub_08085B40(LilypadLargeEntity* this) {
this->unk_78.WORD += 0x100000;
SetAffineInfo(super, this->unk_78.HALF_U.HI, this->unk_78.HALF_U.HI, this->unk_7c.HALF_U.HI);
}
gPlayerEntity.y.HALF.HI = (super->y.HALF.HI + super->z.HALF.HI) - this->unk_74;
gPlayerEntity.base.y.HALF.HI = (super->y.HALF.HI + super->z.HALF.HI) - this->unk_74;
if (gArea.locationIndex == 0x1b) {
gPlayerEntity.z.HALF.HI = super->y.HALF.HI - this->unk_74 - 0xd0 - gPlayerEntity.y.HALF.HI;
gPlayerEntity.base.z.HALF.HI = super->y.HALF.HI - this->unk_74 - 0xd0 - gPlayerEntity.base.y.HALF.HI;
} else {
gPlayerEntity.z.HALF.HI = super->y.HALF.HI - this->unk_74 - 0x40 - gPlayerEntity.y.HALF.HI;
gPlayerEntity.base.z.HALF.HI = super->y.HALF.HI - this->unk_74 - 0x40 - gPlayerEntity.base.y.HALF.HI;
}
}
} else {
ResetCollisionLayer(super);
if (GetActTile(super) == 0xd) {
ResetCollisionLayer(&gPlayerEntity);
ResetCollisionLayer(&gPlayerEntity.base);
LilypadLarge_Action4(this);
super->direction = GetFacingDirection(&gPlayerEntity, super);
LinearMoveDirection(&gPlayerEntity, 0x100, super->direction);
super->direction = GetFacingDirection(&gPlayerEntity.base, super);
LinearMoveDirection(&gPlayerEntity.base, 0x100, super->direction);
}
}
if (this->unk_82 == 0) {
if (GravityUpdate(&gPlayerEntity, Q_8_8(32.0)) == 0) {
ResetCollisionLayer(&gPlayerEntity);
if (GravityUpdate(&gPlayerEntity.base, Q_8_8(32.0)) == 0) {
ResetCollisionLayer(&gPlayerEntity.base);
sub_08085F1C(this);
super->action = 1;
super->subtimer = 4;
@@ -419,23 +418,23 @@ void sub_08085B40(LilypadLargeEntity* this) {
}
void LilypadLarge_Action3(LilypadLargeEntity* this) {
if (sub_0806FC80(super, &gPlayerEntity, 0x18) != 0) {
if (sub_0806FC80(super, &gPlayerEntity.base, 0x18) != 0) {
LinearMoveUpdate(super);
gPlayerEntity.speed = super->speed;
gPlayerEntity.direction = super->direction;
LinearMoveUpdate(&gPlayerEntity);
gPlayerEntity.base.speed = super->speed;
gPlayerEntity.base.direction = super->direction;
LinearMoveUpdate(&gPlayerEntity.base);
gPlayerState.flags |= PL_FLAGS2;
if (super->collisionLayer == 1) {
ResetCollisionLayer(&gPlayerEntity);
ResetCollisionLayer(&gPlayerEntity.base);
} else {
sub_08004542(&gPlayerEntity);
sub_08004542(&gPlayerEntity.base);
}
}
if (gRoomControls.reload_flags == 0) {
super->flags &= ~ENT_PERSIST;
super->action = 1;
super->updatePriority = super->updatePriorityPrev;
gRoomControls.camera_target = &gPlayerEntity;
gRoomControls.camera_target = &gPlayerEntity.base;
}
}
@@ -499,7 +498,7 @@ void sub_08085D60(LilypadLargeEntity* this) {
if (sub_080806BC((super->x.HALF.HI - gRoomControls.origin_x) + tmpX,
(super->y.HALF.HI - gRoomControls.origin_y) + tmpY, r4, 5) == 0) {
if (sub_0807BD14(&gPlayerEntity, r4 >> 3) != 0) {
if (sub_0807BD14(&gPlayerEntity.base, r4 >> 3) != 0) {
super->direction = r4;
sub_08085E74(this);
return;
@@ -515,7 +514,7 @@ void sub_08085D60(LilypadLargeEntity* this) {
tmpX2 = gUnk_08120638[tmp];
tmpY2 = gUnk_08120638[tmp + 1];
if (sub_080B1AF0(super, tmpX2, tmpY2) == 0xff) {
if (sub_0807BD14(&gPlayerEntity, r6 >> 3) != 0) {
if (sub_0807BD14(&gPlayerEntity.base, r6 >> 3) != 0) {
super->direction = (u8)r6;
sub_08085E74(this);
}
@@ -548,9 +547,9 @@ void sub_08085E74(LilypadLargeEntity* this) {
this->unk_6c = 0;
super->x.HALF.LO = 0;
super->y.HALF.LO = 0;
gPlayerEntity.x.HALF.LO = 0;
gPlayerEntity.y.HALF.LO = 0;
gPlayerEntity.direction = super->direction;
gPlayerEntity.base.x.HALF.LO = 0;
gPlayerEntity.base.y.HALF.LO = 0;
gPlayerEntity.base.direction = super->direction;
gPlayerState.animation = ANIM_DEFAULT;
gRoomControls.camera_target = super;
if (gPlayerState.item != NULL) {
@@ -560,13 +559,13 @@ void sub_08085E74(LilypadLargeEntity* this) {
}
void sub_08085EFC(LilypadLargeEntity* this) {
this->unk_76 = super->x.HALF.HI - gPlayerEntity.x.HALF.HI;
this->unk_74 = super->y.HALF.HI - gPlayerEntity.y.HALF.HI;
this->unk_76 = super->x.HALF.HI - gPlayerEntity.base.x.HALF.HI;
this->unk_74 = super->y.HALF.HI - gPlayerEntity.base.y.HALF.HI;
}
void sub_08085F1C(LilypadLargeEntity* this) {
gPlayerEntity.x.HALF.HI = super->x.HALF.HI - this->unk_76;
gPlayerEntity.y.HALF.HI = super->y.HALF.HI - this->unk_74;
gPlayerEntity.base.x.HALF.HI = super->x.HALF.HI - this->unk_76;
gPlayerEntity.base.y.HALF.HI = super->y.HALF.HI - this->unk_74;
sub_0807A5B8(super->direction);
}
-1
View File
@@ -4,7 +4,6 @@
*
* @brief LilypadLargeFalling object
*/
#define NENT_DEPRECATED
#include "entity.h"
#include "functions.h"
#include "object/lilypadLarge.h"
+2 -3
View File
@@ -4,7 +4,6 @@
*
* @brief Lilypad Small object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -43,13 +42,13 @@ void LilypadSmall(LilypadSmallEntity* this) {
static bool32 CheckMovePlayer(LilypadSmallEntity* this) {
if (!(gPlayerState.flags & PL_MINISH)) {
return FALSE;
} else if (EntityInRectRadius(super, &gPlayerEntity, 8, 8) == 0) {
} else if (EntityInRectRadius(super, &gPlayerEntity.base, 8, 8) == 0) {
return FALSE;
} else if (!PlayerCanBeMoved()) {
return FALSE;
} else {
gPlayerState.field_0x14 = 1;
if (gPlayerEntity.z.HALF.HI != 0) {
if (gPlayerEntity.base.z.HALF.HI != 0) {
return FALSE;
} else {
return TRUE;
+10 -11
View File
@@ -5,7 +5,6 @@
* @brief Link Animation object. This is used during "item get" sequences and
* replaces the player entity for the duration.
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "message.h"
#include "object.h"
@@ -53,19 +52,19 @@ void LinkAnimation_ItemGet(LinkAnimationEntity* this) {
u8* ptr;
// hide player entity
gPlayerEntity.flags &= ~ENT_COLLIDE;
gPlayerEntity.spriteSettings.draw = 0;
gPlayerEntity.base.flags &= ~ENT_COLLIDE;
gPlayerEntity.base.spriteSettings.draw = 0;
super->palette.b.b0 = gPlayerEntity.palette.b.b0;
super->palette.b.b0 = gPlayerEntity.base.palette.b.b0;
switch (super->subAction) {
case ITEMGET_INIT:
one = 1;
super->subAction = one;
super->spriteSettings.draw = one;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->spritePriority.b0 = gPlayerEntity.spritePriority.b0;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->spritePriority.b0 = gPlayerEntity.base.spritePriority.b0;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
super->spriteSettings.flipX = 0;
super->animationState = 4;
SetEntityPriority(super, PRIO_PLAYER_EVENT);
@@ -99,9 +98,9 @@ void LinkAnimation_ItemGet(LinkAnimationEntity* this) {
if (super->frame & ANIM_DONE) {
super->action = PLAYER_NORMAL;
// restore player state
gPlayerEntity.flags = this->storeFlags;
gPlayerEntity.spriteSettings.draw = this->storeDrawFlags;
gPlayerEntity.iframes = this->storeIFrames;
gPlayerEntity.base.flags = this->storeFlags;
gPlayerEntity.base.spriteSettings.draw = this->storeDrawFlags;
gPlayerEntity.base.iframes = this->storeIFrames;
gPlayerState.field_0x7 = this->storeField7;
gPlayerState.keepFacing = this->storeKeepFacing;
gPlayerState.field_0xa = this->storeFieldA;
+7 -6
View File
@@ -5,7 +5,6 @@
* @brief Link Emptying Bottle object
* Handles effects of using water, mineral water or a fairy in a bottle in PlayerItemBottle_UseOther.
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "item.h"
#include "object.h"
@@ -40,8 +39,9 @@ void LinkEmptyingBottle_Init(LinkEmptyingBottleEntity* this) {
effect = CreateFx(super, FX_WATER_SPLASH, 0);
super->child = effect;
if (effect != NULL) {
PositionRelative(&gPlayerEntity, effect, gUnk_08122A18[gPlayerEntity.animationState & 6] << 0x10,
gUnk_08122A18[gPlayerEntity.animationState | 1] << 0x10);
PositionRelative(&gPlayerEntity.base, effect,
gUnk_08122A18[gPlayerEntity.base.animationState & 6] << 0x10,
gUnk_08122A18[gPlayerEntity.base.animationState | 1] << 0x10);
}
CopyPosition(super->child, super);
sub_08094980(this, 0x4032, 0x4033);
@@ -51,8 +51,9 @@ void LinkEmptyingBottle_Init(LinkEmptyingBottleEntity* this) {
effect = CreateFx(super, FX_GREEN_SPLASH2, 0);
super->child = effect;
if (effect != NULL) {
PositionRelative(&gPlayerEntity, effect, gUnk_08122A18[gPlayerEntity.animationState & 6] << 0x10,
gUnk_08122A18[gPlayerEntity.animationState | 1] << 0x10);
PositionRelative(&gPlayerEntity.base, effect,
gUnk_08122A18[gPlayerEntity.base.animationState & 6] << 0x10,
gUnk_08122A18[gPlayerEntity.base.animationState | 1] << 0x10);
}
if (super->type2 == 0) {
CopyPosition(super->child, super);
@@ -65,7 +66,7 @@ void LinkEmptyingBottle_Init(LinkEmptyingBottleEntity* this) {
}
break;
case 2:
child = CreateGroundItem(&gPlayerEntity, ITEM_FAIRY, 0);
child = CreateGroundItem(&gPlayerEntity.base, ITEM_FAIRY, 0);
super->child = child;
if (child != NULL) {
child->timer = 1;
+10 -11
View File
@@ -4,7 +4,6 @@
*
* @brief Link Fire object
*/
#define NENT_DEPRECATED
#include "functions.h"
#include "object.h"
@@ -60,22 +59,22 @@ void sub_0808DDE8(LinkFireEntity* this) {
gPlayerState.flags &= ~PL_BURNING;
DeleteThisEntity();
}
player = &gPlayerEntity;
super->x.HALF.HI = (s8)gUnk_081217B8[gPlayerEntity.animationState >> 1] + player->x.HALF.HI;
super->y.HALF.HI = gPlayerEntity.y.HALF.HI + -6;
super->z = gPlayerEntity.z;
super->collisionLayer = gPlayerEntity.collisionLayer;
super->spriteRendering.b3 = gPlayerEntity.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.spriteOrientation.flipY;
player = &gPlayerEntity.base;
super->x.HALF.HI = (s8)gUnk_081217B8[gPlayerEntity.base.animationState >> 1] + player->x.HALF.HI;
super->y.HALF.HI = gPlayerEntity.base.y.HALF.HI + -6;
super->z = gPlayerEntity.base.z;
super->collisionLayer = gPlayerEntity.base.collisionLayer;
super->spriteRendering.b3 = gPlayerEntity.base.spriteRendering.b3;
super->spriteOrientation.flipY = gPlayerEntity.base.spriteOrientation.flipY;
if ((gPlayerState.flags & PL_BURNING) != 0) {
GetNextFrame(super);
} else {
DeleteThisEntity();
}
if (gPlayerEntity.animationState >> 1 == 2) {
sub_0806FEBC(&gPlayerEntity, 3, super);
if (gPlayerEntity.base.animationState >> 1 == 2) {
sub_0806FEBC(&gPlayerEntity.base, 3, super);
super->y.HALF.HI -= 5;
} else {
sub_0806FEBC(&gPlayerEntity, 0, super);
sub_0806FEBC(&gPlayerEntity.base, 0, super);
}
}

Some files were not shown because too many files have changed in this diff Show More