This commit is contained in:
parent
5b785068c2
commit
fa5105d783
96 changed files with 550 additions and 406 deletions
|
@ -30,7 +30,7 @@ void CNpcFriend::processGaryMovement( int _frames )
|
|||
|
||||
// check vertical collision
|
||||
|
||||
groundHeight = m_layerCollision->getHeightFromGround( Pos.vx, Pos.vy, yMovement + 16 );
|
||||
groundHeight = CGameScene::getCollision()->getHeightFromGround( Pos.vx, Pos.vy, yMovement + 16 );
|
||||
|
||||
if ( groundHeight <= 0 )
|
||||
{
|
||||
|
@ -38,7 +38,7 @@ void CNpcFriend::processGaryMovement( int _frames )
|
|||
|
||||
// check horizontal collision
|
||||
|
||||
if ( m_layerCollision->getHeightFromGround( Pos.vx + ( multiplier * _frames ), Pos.vy ) < -maxHeight )
|
||||
if ( CGameScene::getCollision()->getHeightFromGround( Pos.vx + ( multiplier * _frames ), Pos.vy ) < -maxHeight )
|
||||
{
|
||||
// reverse direction
|
||||
|
||||
|
@ -63,7 +63,7 @@ void CNpcFriend::processGaryMovement( int _frames )
|
|||
|
||||
Pos.vy += groundHeight;
|
||||
|
||||
if ( m_layerCollision->getHeightFromGround( Pos.vx + ( multiplier * _frames ), Pos.vy ) < -maxHeight )
|
||||
if ( CGameScene::getCollision()->getHeightFromGround( Pos.vx + ( multiplier * _frames ), Pos.vy ) < -maxHeight )
|
||||
{
|
||||
// reverse direction
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue