mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-14 08:30:50 +00:00
Merge branch 'master' of http://github.com/rheit/zdoom
This commit is contained in:
commit
fb8c05bcb3
4 changed files with 7 additions and 9 deletions
|
@ -640,6 +640,7 @@ void AWeapon::PostMorphWeapon ()
|
||||||
|
|
||||||
pspr = Owner->player->GetPSprite(PSP_WEAPON);
|
pspr = Owner->player->GetPSprite(PSP_WEAPON);
|
||||||
pspr->y = WEAPONBOTTOM;
|
pspr->y = WEAPONBOTTOM;
|
||||||
|
pspr->ResetInterpolation();
|
||||||
pspr->SetState(GetUpState());
|
pspr->SetState(GetUpState());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -262,8 +262,7 @@ void DPSprite::NewTick()
|
||||||
while (pspr)
|
while (pspr)
|
||||||
{
|
{
|
||||||
pspr->processPending = true;
|
pspr->processPending = true;
|
||||||
pspr->oldx = pspr->x;
|
pspr->ResetInterpolation();
|
||||||
pspr->oldy = pspr->y;
|
|
||||||
|
|
||||||
pspr = pspr->Next;
|
pspr = pspr->Next;
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,11 +29,8 @@
|
||||||
|
|
||||||
#define WEAPONBOTTOM 128.
|
#define WEAPONBOTTOM 128.
|
||||||
|
|
||||||
// [RH] +0x6000 helps it meet the screen bottom
|
#define WEAPONTOP 32.
|
||||||
// at higher resolutions while still being in
|
#define WEAPON_FUDGE_Y 0.375
|
||||||
// the right spot at 320x200.
|
|
||||||
#define WEAPONTOP (32+6./16)
|
|
||||||
|
|
||||||
class AInventory;
|
class AInventory;
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -78,6 +75,7 @@ public:
|
||||||
DPSprite* GetNext() { return Next; }
|
DPSprite* GetNext() { return Next; }
|
||||||
AActor* GetCaller() { return Caller; }
|
AActor* GetCaller() { return Caller; }
|
||||||
void SetCaller(AActor *newcaller) { Caller = newcaller; }
|
void SetCaller(AActor *newcaller) { Caller = newcaller; }
|
||||||
|
void ResetInterpolation() { oldx = x; oldy = y; }
|
||||||
|
|
||||||
double x, y;
|
double x, y;
|
||||||
double oldx, oldy;
|
double oldx, oldy;
|
||||||
|
|
|
@ -1319,7 +1319,7 @@ void R_DrawPSprite(DPSprite *pspr, AActor *owner, float bobx, float boby, double
|
||||||
}
|
}
|
||||||
|
|
||||||
sx = pspr->oldx + (pspr->x - pspr->oldx) * ticfrac;
|
sx = pspr->oldx + (pspr->x - pspr->oldx) * ticfrac;
|
||||||
sy = pspr->oldy + (pspr->y - pspr->oldy) * ticfrac;
|
sy = pspr->oldy + (pspr->y - pspr->oldy) * ticfrac + WEAPON_FUDGE_Y;
|
||||||
|
|
||||||
if (pspr->Flags & PSPF_ADDBOB)
|
if (pspr->Flags & PSPF_ADDBOB)
|
||||||
{
|
{
|
||||||
|
@ -1632,7 +1632,7 @@ void R_DrawPlayerSprites ()
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
wx = weapon->oldx + (weapon->x - weapon->oldx) * r_TicFracF;
|
wx = weapon->oldx + (weapon->x - weapon->oldx) * r_TicFracF;
|
||||||
wy = weapon->oldy + (weapon->y - weapon->oldy) * r_TicFracF;
|
wy = weapon->oldy + (weapon->y - weapon->oldy) * r_TicFracF + WEAPON_FUDGE_Y;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue