mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 03:00:46 +00:00
This hopefully corrects the bug where animation smoothing sometimes substitutes models with bags of shit.
git-svn-id: https://svn.eduke32.com/eduke32@971 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
317cd92271
commit
68e7e307ae
2 changed files with 20 additions and 0 deletions
|
@ -1478,6 +1478,25 @@ static int md3draw(md3model *m, spritetype *tspr)
|
||||||
|
|
||||||
f = m->interpol; g = 1-f;
|
f = m->interpol; g = 1-f;
|
||||||
|
|
||||||
|
if (m->interpol < 0 || m->interpol > 1 ||
|
||||||
|
m->cframe < 0 || m->cframe >= m->numframes ||
|
||||||
|
m->nframe < 0 || m->nframe >= m->numframes)
|
||||||
|
{
|
||||||
|
OSD_Printf("Model frame out of bounds!\n");
|
||||||
|
if (m->interpol < 0)
|
||||||
|
m->interpol = 0;
|
||||||
|
if (m->interpol > 1)
|
||||||
|
m->interpol = 1;
|
||||||
|
if (m->cframe < 0)
|
||||||
|
m->cframe = 0;
|
||||||
|
if (m->cframe >= m->numframes)
|
||||||
|
m->cframe = m->numframes - 1;
|
||||||
|
if (m->nframe < 0)
|
||||||
|
m->nframe = 0;
|
||||||
|
if (m->nframe >= m->numframes)
|
||||||
|
m->nframe = m->numframes - 1;
|
||||||
|
}
|
||||||
|
|
||||||
if (m->head.flags == 1337)
|
if (m->head.flags == 1337)
|
||||||
{
|
{
|
||||||
// md2
|
// md2
|
||||||
|
|
|
@ -4628,6 +4628,7 @@ int EGS(int whatsect,int s_x,int s_y,int s_z,int s_pn,int s_s,int s_xr,int s_yr,
|
||||||
else show2dsprite[i>>3] &= ~(1<<(i&7));
|
else show2dsprite[i>>3] &= ~(1<<(i&7));
|
||||||
|
|
||||||
clearbufbyte(&spriteext[i], sizeof(spriteexttype), 0);
|
clearbufbyte(&spriteext[i], sizeof(spriteexttype), 0);
|
||||||
|
clearbufbyte(&spritesmooth[i], sizeof(spritesmoothtype), 0);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
if(s->sectnum < 0)
|
if(s->sectnum < 0)
|
||||||
|
|
Loading…
Reference in a new issue