mirror of
https://github.com/ZDoom/gzdoom-last-svn.git
synced 2025-05-30 00:41:19 +00:00
- Fixed model float-bobbing by having the bob offset applied earlier in GLSprite::Process().
git-svn-id: http://mancubus.net/svn/hosted/gzdoom/trunk@1556 b0f79afe-0144-0410-b225-9a4edf0717df
This commit is contained in:
parent
adeb34ed6f
commit
24e09cf31a
1 changed files with 8 additions and 10 deletions
|
@ -514,6 +514,13 @@ void GLSprite::Process(AActor* thing,sector_t * sector)
|
|||
x = FIXED2FLOAT(thingx);
|
||||
z = FIXED2FLOAT(thingz-thing->floorclip);
|
||||
y = FIXED2FLOAT(thingy);
|
||||
|
||||
// [RH] Make floatbobbing a renderer-only effect.
|
||||
if (thing->flags2 & MF2_FLOATBOB)
|
||||
{
|
||||
float fz = FIXED2FLOAT(thing->GetBobOffset(r_TicFrac));
|
||||
z += fz;
|
||||
}
|
||||
|
||||
modelframe = gl_FindModelFrame(RUNTIME_TYPE(thing), spritenum, thing->frame, !!(thing->flags & MF_DROPPED));
|
||||
if (!modelframe)
|
||||
|
@ -668,16 +675,7 @@ void GLSprite::Process(AActor* thing,sector_t * sector)
|
|||
x1=x-viewvecY*leftfac;
|
||||
x2=x-viewvecY*rightfac;
|
||||
y1=y+viewvecX*leftfac;
|
||||
y2=y+viewvecX*rightfac;
|
||||
|
||||
// [RH] Make floatbobbing a renderer-only effect.
|
||||
if (thing->flags2 & MF2_FLOATBOB)
|
||||
{
|
||||
float fz = FIXED2FLOAT(thing->GetBobOffset(r_TicFrac));
|
||||
z1 += fz;
|
||||
z2 += fz;
|
||||
}
|
||||
|
||||
y2=y+viewvecX*rightfac;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue