diff --git a/source/build/src/clip.cpp b/source/build/src/clip.cpp index 4b46208d6..fcba3addb 100644 --- a/source/build/src/clip.cpp +++ b/source/build/src/clip.cpp @@ -603,7 +603,7 @@ CollisionBase clipmove_(vec3_t * const pos, int * const sectnum, int32_t xvect, if (enginecompatibility_mode != ENGINECOMPATIBILITY_NONE) { - DVector3 fpos(pos->X* inttoworld, pos->Y* inttoworld, pos->Z* inttoworld); + DVector3 fpos(pos->X* inttoworld, pos->Y* inttoworld, pos->Z* zinttoworld); for (int j=0; jspr.pos.plusZ(-zH - maptoworld); + auto pos = actor->spr.pos.plusZ(-zH - zmaptoworld); FAFgetzrange(pos, actor->sector(), &globhiz, &globhihit, &globloz, &globlohit, actor->clipdist - GETZRANGE_CLIP_ADJ, cliptype); @@ -6544,7 +6544,7 @@ int MissileZrange(DSWActor* actor) auto tempshort = actor->spr.cstat; actor->spr.cstat &= ~(CSTAT_SPRITE_BLOCK); - FAFgetzrangepoint(actor->spr.pos.plusZ(-maptoworld), actor->sector(), &globhiz, &globhihit, &globloz, &globlohit); + FAFgetzrangepoint(actor->spr.pos.plusZ(-zmaptoworld), actor->sector(), &globhiz, &globhihit, &globloz, &globlohit); actor->spr.cstat = tempshort; diff --git a/source/games/sw/src/weapon.cpp b/source/games/sw/src/weapon.cpp index 16140f71a..ccf5ab6fa 100644 --- a/source/games/sw/src/weapon.cpp +++ b/source/games/sw/src/weapon.cpp @@ -14981,7 +14981,7 @@ int InitCoolgFire(DSWActor* actor) int DoCoolgDrip(DSWActor* actor) { actor->user.Counter += 220; - actor->spr.pos.Z += actor->user.Counter * maptoworld; + actor->spr.pos.Z += actor->user.Counter * zmaptoworld; if (actor->spr.pos.Z > actor->user.loz - actor->user.floor_dist) {