mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-26 03:30:46 +00:00
Polymer: Fix the oversight in handling tspr->extra from r5400 by setting it to zero in polymer_scansprites.
git-svn-id: https://svn.eduke32.com/eduke32@5769 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
0434a87e3a
commit
f0f7b04652
2 changed files with 2 additions and 9 deletions
|
@ -3832,6 +3832,7 @@ static inline void polymer_scansprites(int16_t sectnum, tspritetype* localtspri
|
||||||
// this function's localtsprite is either the tsprite global or
|
// this function's localtsprite is either the tsprite global or
|
||||||
// polymer_drawroom's locattsprite, so no aliasing
|
// polymer_drawroom's locattsprite, so no aliasing
|
||||||
Bmemcpy(&localtsprite[*localspritesortcnt], spr, sizeof(spritetype));
|
Bmemcpy(&localtsprite[*localspritesortcnt], spr, sizeof(spritetype));
|
||||||
|
localtsprite[*localspritesortcnt].extra = 0;
|
||||||
localtsprite[(*localspritesortcnt)++].owner = i;
|
localtsprite[(*localspritesortcnt)++].owner = i;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -4690,16 +4691,10 @@ static void polymer_drawmdsprite(tspritetype *tspr)
|
||||||
sk->skinnum == tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum &&
|
sk->skinnum == tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum &&
|
||||||
sk->surfnum == surfi)
|
sk->surfnum == surfi)
|
||||||
mdspritematerial.detailscale[0] = mdspritematerial.detailscale[1] = sk->param;
|
mdspritematerial.detailscale[0] = mdspritematerial.detailscale[1] = sk->param;
|
||||||
}
|
|
||||||
|
|
||||||
if (!(tspr->extra&TSPR_EXTRA_MDHACK))
|
|
||||||
{
|
|
||||||
mdspritematerial.specmap =
|
mdspritematerial.specmap =
|
||||||
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,SPECULARPAL,surfi);
|
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,SPECULARPAL,surfi);
|
||||||
}
|
|
||||||
|
|
||||||
if (!(tspr->extra&TSPR_EXTRA_MDHACK))
|
|
||||||
{
|
|
||||||
mdspritematerial.normalmap =
|
mdspritematerial.normalmap =
|
||||||
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,NORMALPAL,surfi);
|
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,NORMALPAL,surfi);
|
||||||
|
|
||||||
|
@ -4710,10 +4705,7 @@ static void polymer_drawmdsprite(tspritetype *tspr)
|
||||||
mdspritematerial.normalbias[0] = sk->specpower;
|
mdspritematerial.normalbias[0] = sk->specpower;
|
||||||
mdspritematerial.normalbias[1] = sk->specfactor;
|
mdspritematerial.normalbias[1] = sk->specfactor;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if (!(tspr->extra&TSPR_EXTRA_MDHACK))
|
|
||||||
{
|
|
||||||
mdspritematerial.glowmap =
|
mdspritematerial.glowmap =
|
||||||
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,GLOWPAL,surfi);
|
mdloadskin((md2model_t *)m,tile2model[Ptile2tile(tspr->picnum,lpal)].skinnum,GLOWPAL,surfi);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2524,6 +2524,7 @@ void polymost_editorfunc(void)
|
||||||
tsp->shade = 30-shd;
|
tsp->shade = 30-shd;
|
||||||
tsp->owner = MAXSPRITES-1;
|
tsp->owner = MAXSPRITES-1;
|
||||||
tsp->xrepeat = tsp->yrepeat = min(max(1, (int32_t) (dadist*((double)(shd*3)/3200.0))), 255);
|
tsp->xrepeat = tsp->yrepeat = min(max(1, (int32_t) (dadist*((double)(shd*3)/3200.0))), 255);
|
||||||
|
tsp->extra = 0;
|
||||||
sprite[tsp->owner].xoffset = sprite[tsp->owner].yoffset = 0;
|
sprite[tsp->owner].xoffset = sprite[tsp->owner].yoffset = 0;
|
||||||
tspriteptr[spritesortcnt++] = tsp;
|
tspriteptr[spritesortcnt++] = tsp;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue