Merge branch 'Saturn-Next' into Saturn-Testing

This commit is contained in:
Alug committed 2025-08-19 11:49:56 +02:00
commit 6dee986a28
3 files changed
+17 -36

No files matched your search

+4 -2
View File
@@ -9855,7 +9855,6 @@ mobj_t *P_SpawnShadowMobj(mobj_t * caster)
mobj->radius = info->radius;
mobj->height = info->height;
mobj->flags = info->flags;
mobj->blendmode = AST_TRANSLUCENT;
mobj->health = info->spawnhealth;
@@ -9891,7 +9890,10 @@ mobj_t *P_SpawnShadowMobj(mobj_t * caster)
}
// Sprite rendering
mobj->spritexscale = mobj->spriteyscale = mobj->scale;
mobj->blendmode = AST_TRANSLUCENT;
mobj->realxscale = mobj->realyscale = mobj->scale;
mobj->spritexscale = mobj->realxscale;
mobj->spriteyscale = mobj->realyscale;
// set subsector and/or block links
P_SetThingPosition(mobj);
-34
View File
@@ -627,38 +627,6 @@ static void P_RunQuakes(void)
--quake.time;
}
// Reset our Sprite scales and offsets
// at the start of our tic
// this is just to make things simpler
// as we dont have to reset it ourselves after use
// done at the start so lua can still overwrite everything
static inline void P_ResetSpriteStuff(void)
{
thinker_t *th;
if (rendermode == render_none)
return;
for (th = thinkercap.next; th != &thinkercap; th = th->next)
{
mobj_t *mo;
if (th->function != (actionf_p1)P_MobjThinker) // not a mobj
continue;
mo = (mobj_t *)th;
if (!mo || (mo->sprite == SPR_NULL)
|| (mo->flags2 & MF2_DONTDRAW) || (mo->type == MT_SHADOW))
continue;
mo->spritexscale = mo->realxscale;
mo->spriteyscale = mo->realyscale;
mo->spritexoffset = mo->realxoffset;
mo->spriteyoffset = mo->realyoffset;
}
}
//
// P_Ticker
//
@@ -760,8 +728,6 @@ void P_Ticker(boolean run)
ps_lua_mobjhooks.value.i = 0;
ps_checkposition_calls.value.i = 0;
P_ResetSpriteStuff();
PS_START_TIMING(ps_lua_prethinkframe_time);
LUA_HookPreThinkFrame();
PS_STOP_TIMING(ps_lua_prethinkframe_time);
+13
View File
@@ -860,6 +860,19 @@ void R_ResetMobjInterpolationState(mobj_t *mobj)
mobj->player->old_frameangle = mobj->player->frameangle;
}
// Reset our Sprite scales and offsets
// at the start of the tic
// this is just to make things simpler
// as we dont have to reset it ourselves after use
// done at the start so lua can still overwrite everything
// technically not interpolation related
// but this saves us another thinkerloop and multiple checks lel
mobj->spritexscale = mobj->realxscale;
mobj->spriteyscale = mobj->realyscale;
mobj->spritexoffset = mobj->realxoffset;
mobj->spriteyoffset = mobj->realyoffset;
mobj->resetinterp = false;
}