mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-12-01 08:31:14 +00:00
Fixed: the weapon layer offsets were interpolated even after the player switched his weapon
This commit is contained in:
parent
75cb8c00a6
commit
da6e12d5bc
1 changed files with 4 additions and 1 deletions
|
@ -220,7 +220,7 @@ DPSprite *player_t::GetPSprite(PSPLayers layer)
|
||||||
pspr->Caller = newcaller;
|
pspr->Caller = newcaller;
|
||||||
|
|
||||||
if (newcaller != oldcaller)
|
if (newcaller != oldcaller)
|
||||||
{ // Only reset flags if this layer was created now or if it was being used before.
|
{ // Only reset stuff if this layer was created now or if it was being used before.
|
||||||
if (layer >= PSP_TARGETCENTER)
|
if (layer >= PSP_TARGETCENTER)
|
||||||
{ // The targeter layers were affected by those.
|
{ // The targeter layers were affected by those.
|
||||||
pspr->Flags = (PSPF_CVARFAST|PSPF_POWDOUBLE);
|
pspr->Flags = (PSPF_CVARFAST|PSPF_POWDOUBLE);
|
||||||
|
@ -229,6 +229,9 @@ DPSprite *player_t::GetPSprite(PSPLayers layer)
|
||||||
{
|
{
|
||||||
pspr->Flags = (PSPF_ADDWEAPON|PSPF_ADDBOB|PSPF_CVARFAST|PSPF_POWDOUBLE);
|
pspr->Flags = (PSPF_ADDWEAPON|PSPF_ADDBOB|PSPF_CVARFAST|PSPF_POWDOUBLE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pspr->oldx = pspr->x;
|
||||||
|
pspr->oldy = pspr->y;
|
||||||
}
|
}
|
||||||
|
|
||||||
return pspr;
|
return pspr;
|
||||||
|
|
Loading…
Reference in a new issue