This commit is contained in:
Charles 2001-07-27 13:31:52 +00:00
parent 3a05eb9884
commit 035d72263d
20 changed files with 44 additions and 39 deletions

View file

@ -626,7 +626,7 @@ void CNpcSeaSnakeEnemy::updateTail( DVECTOR &oldPos, int _frames )
s32 xDist = oldPos.vx - newPos->pos.vx;
s32 yDist = oldPos.vy - newPos->pos.vy;
s16 headingToTarget = ratan2( yDist, xDist );
s16 headingToTarget = ratan2( yDist, xDist ) & 4095;
DVECTOR sinPos;
@ -684,7 +684,7 @@ void CNpcSeaSnakeEnemy::updateTail( DVECTOR &oldPos, int _frames )
s32 xDist = oldPos.vx - currentPos.vx;
s32 yDist = oldPos.vy - currentPos.vy;
s16 headingToPrev = ratan2( yDist, xDist );
s16 headingToPrev = ratan2( yDist, xDist ) & 4095;
s16 headingFromNext;
s16 heading = headingToPrev;
@ -695,7 +695,7 @@ void CNpcSeaSnakeEnemy::updateTail( DVECTOR &oldPos, int _frames )
DVECTOR const &nextPos = m_segmentArray[segmentCount + 1].getPos();
xDist = currentPos.vx - nextPos.vx;
yDist = currentPos.vy - nextPos.vy;
headingFromNext = ratan2( yDist, xDist );
headingFromNext = ratan2( yDist, xDist ) & 4095;
s16 decDir, incDir, moveDist;