Modificada la seqëncia d'inici per a que la musica començe antes
This commit is contained in:
@@ -1044,8 +1044,7 @@ void Game::disableTimeStopItem()
|
|||||||
void Game::checkMusicStatus()
|
void Game::checkMusicStatus()
|
||||||
{
|
{
|
||||||
// Si se ha completado el juego o los jugadores han terminado, detiene la música
|
// Si se ha completado el juego o los jugadores han terminado, detiene la música
|
||||||
// if (state_ != GameState::COMPLETED && !allPlayersAreGameOver())
|
if (state_ == GameState::PLAYING || state_ == GameState::SHOWING_GET_READY_MESSAGE)
|
||||||
if (state_ == GameState::PLAYING)
|
|
||||||
{
|
{
|
||||||
playMusic();
|
playMusic();
|
||||||
}
|
}
|
||||||
@@ -1872,7 +1871,7 @@ void Game::updateGameStateEnteringPlayer()
|
|||||||
{
|
{
|
||||||
state_ = GameState::SHOWING_GET_READY_MESSAGE;
|
state_ = GameState::SHOWING_GET_READY_MESSAGE;
|
||||||
createMessage({paths_.at(0), paths_.at(1)}, Resource::get()->getTexture("game_text_get_ready"));
|
createMessage({paths_.at(0), paths_.at(1)}, Resource::get()->getTexture("game_text_get_ready"));
|
||||||
JA_PlaySound(Resource::get()->getSound("voice_get_ready.wav"));
|
//JA_PlaySound(Resource::get()->getSound("voice_get_ready.wav"));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1891,6 +1890,10 @@ void Game::updateGameStateShowingGetReadyMessage()
|
|||||||
{
|
{
|
||||||
state_ = GameState::PLAYING;
|
state_ = GameState::PLAYING;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
path_sprites_.front()->getCurrentPath()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Actualiza las variables durante el transcurso normal del juego
|
// Actualiza las variables durante el transcurso normal del juego
|
||||||
|
|||||||
@@ -73,4 +73,7 @@ public:
|
|||||||
|
|
||||||
// Indica si ha terminado todos los recorridos
|
// Indica si ha terminado todos los recorridos
|
||||||
bool hasFinished();
|
bool hasFinished();
|
||||||
|
|
||||||
|
// Getters
|
||||||
|
int getCurrentPath() const { return current_path_; }
|
||||||
};
|
};
|
||||||
Reference in New Issue
Block a user