mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-10 14:52:01 +00:00
- map fix for Hickston Swamp (RR mod) E1L3:
Wall sprite is placed in the wrong sector which makes the new renderer's far stricter checks to reduce sprite flicker fail to position it correctly.
This commit is contained in:
parent
20ca676539
commit
5556756d43
3 changed files with 27 additions and 0 deletions
|
@ -77,16 +77,31 @@ inline DVector2 WallDelta(const walltype* wallnum)
|
||||||
return WallEnd(wallnum) - WallStart(wallnum);
|
return WallEnd(wallnum) - WallStart(wallnum);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline double SpriteX(spritetype* spr)
|
||||||
|
{
|
||||||
|
return spr->x * (1 / 16.);
|
||||||
|
}
|
||||||
|
|
||||||
inline double SpriteX(int wallnum)
|
inline double SpriteX(int wallnum)
|
||||||
{
|
{
|
||||||
return sprite[wallnum].x * (1 / 16.);
|
return sprite[wallnum].x * (1 / 16.);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline double SpriteY(spritetype* spr)
|
||||||
|
{
|
||||||
|
return spr->y * (1 / -16.);
|
||||||
|
}
|
||||||
|
|
||||||
inline double SpriteY(int wallnum)
|
inline double SpriteY(int wallnum)
|
||||||
{
|
{
|
||||||
return sprite[wallnum].y * (1 / -16.);
|
return sprite[wallnum].y * (1 / -16.);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
inline DVector2 SpritePos(spritetype* spr)
|
||||||
|
{
|
||||||
|
return { SpriteX(spr), SpriteY(spr) };
|
||||||
|
}
|
||||||
|
|
||||||
inline double PointOnLineSide(double x, double y, double linex, double liney, double deltax, double deltay)
|
inline double PointOnLineSide(double x, double y, double linex, double liney, double deltax, double deltay)
|
||||||
{
|
{
|
||||||
return (x - linex) * deltay - (y - liney) * deltax;
|
return (x - linex) * deltay - (y - liney) * deltax;
|
||||||
|
|
|
@ -146,6 +146,16 @@ static int32_t LoadMapHack(const char *filename)
|
||||||
blockingpairs[currentwall].Push(sc.Number);
|
blockingpairs[currentwall].Push(sc.Number);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (sc.Compare("sector"))
|
||||||
|
{
|
||||||
|
if (sc.CheckNumber())
|
||||||
|
{
|
||||||
|
if (currentsprite != -1 && validateSprite())
|
||||||
|
{
|
||||||
|
sprite[currentsprite].sectnum = sc.Number;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
else if (sc.Compare("picnum"))
|
else if (sc.Compare("picnum"))
|
||||||
{
|
{
|
||||||
if (sc.CheckNumber())
|
if (sc.CheckNumber())
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
// Hickston Swamp E1L3 (RR mod) wall sprite in wrong sector flickers with new renderer
|
||||||
|
sprite 225 sector 565
|
Loading…
Reference in a new issue