Merge branch 'interpolate-maria' into 'next'

Interpolate Shadows when Scaling Mobjs

See merge request STJr/SRB2!1986
This commit is contained in:
sphere 2023-06-12 23:39:23 +00:00
commit 5307c1635d
2 changed files with 4 additions and 0 deletions

View file

@ -3606,6 +3606,8 @@ static void HWR_DrawDropShadow(mobj_t *thing, fixed_t scale)
scalemul = FixedMul(FRACUNIT - floordiff/640, scale);
scalemul = FixedMul(scalemul, (thing->radius*2) / gpatch->height);
if ((thing->scale != thing->old_scale) && (thing->scale >= FRACUNIT/1024)) // Interpolate shadows when scaling mobjs
scalemul = FixedMul(scalemul, FixedDiv(interp.scale, thing->scale));
fscale = FIXED_TO_FLOAT(scalemul);
fx = FIXED_TO_FLOAT(interp.x);

View file

@ -1324,6 +1324,8 @@ static void R_ProjectDropShadow(mobj_t *thing, vissprite_t *vis, fixed_t scale,
if (trans >= 9) return;
scalemul = FixedMul(FRACUNIT - floordiff/640, scale);
if ((thing->scale != thing->old_scale) && (thing->scale >= FRACUNIT/1024)) // Interpolate shadows when scaling mobjs
scalemul = FixedMul(scalemul, FixedDiv(interp.scale, thing->scale));
patch = W_CachePatchName("DSHADOW", PU_SPRITE);
xscale = FixedDiv(projection, tz);