From 2616808febfdce91200449b371dc91e1b3a5096a Mon Sep 17 00:00:00 2001 From: Sonic Dreamcaster Date: Tue, 31 Dec 2024 18:53:04 -0300 Subject: [PATCH] Item/Effect Draw/Dispawn fix --- src/engine/fox_edisplay.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/engine/fox_edisplay.c b/src/engine/fox_edisplay.c index 0fc6f88d..3d7b6542 100644 --- a/src/engine/fox_edisplay.c +++ b/src/engine/fox_edisplay.c @@ -1375,7 +1375,8 @@ void Effect_DrawAllRange(Effect* this) { } if ((dest.z < 0.0f) && (minZ < dest.z)) { - if (fabsf(dest.x) < (fabsf(dest.z * 0.5f) + 500.0f)) { + // @port: Extend draw distance up to 32/9 + if (fabsf(dest.x) < (fabsf(dest.z * /* 0.5f */ 1.5f) + 500.0f)) { if (fabsf(dest.y) < (fabsf(dest.z * 0.5f) + 500.0f)) { if (this->info.draw != NULL) { Matrix_RotateY(gGfxMatrix, this->obj.rot.y * M_DTOR, MTXF_APPLY); @@ -1406,13 +1407,10 @@ void Item_Draw(Item* this, s32 arg1) { drawn = false; - // @port draw no matter what - goto render; - if ((dest.z < 0.0f) && (dest.z > -12000.0f)) { - if (fabsf(dest.x) < (fabsf(dest.z * 0.5f) + 500.0f)) { + // @port: Extend draw distance up to 32/9 + if (fabsf(dest.x) < (fabsf(dest.z * /* 0.5f */ 1.5f) + 500.0f)) { if (fabsf(dest.y) < (fabsf(dest.z * 0.5f) + 500.0f)) { - render: if (this->info.draw != NULL) { Matrix_RotateY(gGfxMatrix, this->obj.rot.y * M_DTOR, MTXF_APPLY); Matrix_RotateX(gGfxMatrix, this->obj.rot.x * M_DTOR, MTXF_APPLY);