Skip to content

Commit

Permalink
- use the same formula as Duke to offset SW's shadows in Polymost.
Browse files Browse the repository at this point in the history
  • Loading branch information
coelckers committed May 29, 2021
1 parent 39b84c4 commit a7921e4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions source/games/sw/src/draw.cpp
Expand Up @@ -351,10 +351,10 @@ DoShadows(spritetype* tsprite, int& spritesortcnt, tspriteptr_t tsp, int viewz,
}
else if (!testnewrenderer)
{
int const camang = mirror ? NORM_ANGLE(2048 - Player[screenpeek].siang) : Player[screenpeek].siang;
New->x += bcos(camang, -11);
New->y += bsin(camang, -11);

// Alter the shadow's position so that it appears behind the sprite itself.
int look = getangle(New->x - Player[screenpeek].six, New->y - Player[screenpeek].siy);
New->x += bcos(look, -9);
New->y += bsin(look, -9);
}
else New->time = 1;

Expand Down

0 comments on commit a7921e4

Please sign in to comment.