mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
Fix ceiling panning angle
This commit is contained in:
parent
0d54237eec
commit
1d8a11601d
1 changed files with 2 additions and 2 deletions
|
@ -300,9 +300,9 @@ void DoSectorPanning(void)
|
|||
if (pSector->ceilingstat & CSTAT_SECTOR_ALIGN)
|
||||
angle -= 512;
|
||||
int xBits = tileWidth(nTile) >> int((pSector->ceilingstat & CSTAT_SECTOR_TEXHALF) != 0);
|
||||
int px = MulScale(speed << 2, Cos(angle), 30) / xBits;
|
||||
int px = MulScale(speed << 2, Cos(-angle), 30) / xBits;
|
||||
int yBits = tileHeight(nTile) >> int((pSector->ceilingstat & CSTAT_SECTOR_TEXHALF) != 0);
|
||||
int py = MulScale(speed << 2, Sin(angle), 30) / yBits;
|
||||
int py = MulScale(speed << 2, Sin(-angle), 30) / yBits;
|
||||
pSector->addceilingxpan(px * (1.f / 256));
|
||||
pSector->addceilingypan(-py * (1.f / 256));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue