mirror of
https://github.com/wavemotion-dave/NINTV-DS.git
synced 2025-06-18 13:55:33 -04:00
Version 5.8 released. New overlays and collision detection improvements.
This commit is contained in:
parent
5d2a568568
commit
df933f48d8
BIN
NINTV-DS.nds
BIN
NINTV-DS.nds
Binary file not shown.
@ -1253,12 +1253,12 @@ ITCM_CODE BOOL AY38900::mobsCollide(int mobNum0, int mobNum1)
|
||||
{
|
||||
if (((mobBuffers[mobNum0][offsetYr0 + y] << offsetXr0) & (mobBuffers[mobNum1][offsetYr1 + y] << offsetXr1)) != 0)
|
||||
{
|
||||
// -----------------------------------------------------------------------------------------------------
|
||||
// ---------------------------------------------------------------------------------------------------------
|
||||
// Make sure the vertical area of this overlap is visible on screen ... otherwise no collision
|
||||
// Since we've already determined a collision, we only need to check one of the MOB rectangles to see
|
||||
// if it is off-screen as the other one would be likewise... In theory, we should check off bottom too.
|
||||
// -----------------------------------------------------------------------------------------------------
|
||||
if ((r0->y + ((offsetYr0/2) + y) + verticalOffset) >= 0) return TRUE;
|
||||
// if it is off-screen as the other one would be likewise... In theory, we should check outside bottom too.
|
||||
// ---------------------------------------------------------------------------------------------------------
|
||||
if ((r0->y + (offsetYr0 + y + verticalOffset)) >= 0) return TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user