This commit is contained in:
parent
1da64afa81
commit
c7fe8c740b
70 changed files with 302 additions and 445 deletions
|
@ -99,15 +99,15 @@ int CNpcBubblePlatform::checkCollisionAgainst(CThing *_thisThing, int _frames)
|
|||
thisRect = getCollisionArea();
|
||||
thatRect = _thisThing->getCollisionArea();
|
||||
|
||||
DVECTOR posDelta = getPosDelta();
|
||||
DVECTOR const &thisPosDelta = getPosDelta();
|
||||
int ThisAbsY=abs(thisPosDelta.vy)>>1;
|
||||
thisRect.y1 -= ThisAbsY;
|
||||
thisRect.y2 += ThisAbsY;
|
||||
|
||||
thisRect.y1 -= abs( posDelta.vy ) >> 1;
|
||||
thisRect.y2 += abs( posDelta.vy ) >> 1;
|
||||
|
||||
posDelta = _thisThing->getPosDelta();
|
||||
|
||||
thatRect.y1 -= abs( posDelta.vy ) >> 1;
|
||||
thatRect.y2 += abs( posDelta.vy ) >> 1;
|
||||
DVECTOR const &ThatPosDelta = _thisThing->getPosDelta();
|
||||
int ThatAbsY=abs(ThatPosDelta.vy)>>1;
|
||||
thatRect.y1 -= ThatAbsY;
|
||||
thatRect.y2 += ThatAbsY;
|
||||
|
||||
if(((thisRect.x1>=thatRect.x1&&thisRect.x1<=thatRect.x2)||(thisRect.x2>=thatRect.x1&&thisRect.x2<=thatRect.x2)||(thisRect.x1<=thatRect.x1&&thisRect.x2>=thatRect.x2))&&
|
||||
((thisRect.y1>=thatRect.y1&&thisRect.y1<=thatRect.y2)||(thisRect.y2>=thatRect.y1&&thisRect.y2<=thatRect.y2)||(thisRect.y1<=thatRect.y1&&thisRect.y2>=thatRect.y2)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue