El salto ya hace el arco y luego cae

This commit is contained in:
2022-07-11 10:52:20 +02:00
parent 783689c368
commit 38f95d9724
4 changed files with 23 additions and 18 deletions

View File

@@ -187,9 +187,6 @@ bool Game::changeRoom(std::string file)
// Crea un objeto habitación nuevo a partir del fichero
mRoom = new Room(mAsset->get(file), mRenderer, mAsset);
// Comunica al jugador la nueva referencia para la habitación
mPlayer->setRoom(mRoom);
success = true;
}
@@ -216,7 +213,7 @@ void Game::checkPlayerOnFloor()
// *** HAY UN POSIBLE PROBLEMA y es que caiga muy rapido y viaje a mas de un pixel de velocidad,
// con lo que se saltaria la comprobación
if ((mPlayer->getVelY() >= 0) && ((int)mPlayer->getLeftFoot().y % 8 == 0))
{ // Comprueba ambos pies
bool test = false;