primera implementació dels estats nous del jugador: playing, continue, waiting
This commit is contained in:
@@ -345,6 +345,12 @@ void Player::setStatusPlaying(int value)
|
||||
}
|
||||
}
|
||||
|
||||
// Obtiene el estado del jugador en el juego
|
||||
int Player::getStatusPlaying()
|
||||
{
|
||||
return statusPlaying;
|
||||
}
|
||||
|
||||
// Obtiene el valor de la variable
|
||||
float Player::getScoreMultiplier()
|
||||
{
|
||||
@@ -514,12 +520,6 @@ void Player::shiftColliders()
|
||||
collider.y = int(posY + (height / 2));
|
||||
}
|
||||
|
||||
// Obtiene el puntero a la textura con los gráficos de la animación de morir
|
||||
Texture *Player::getDeadTexture()
|
||||
{
|
||||
return playerSprite->getTexture();
|
||||
}
|
||||
|
||||
// Pone las texturas del jugador
|
||||
void Player::setPlayerTextures(std::vector<Texture *> texture)
|
||||
{
|
||||
@@ -547,6 +547,23 @@ void Player::updateContinueCounter()
|
||||
|
||||
// Decrementa el contador
|
||||
continueCounter--;
|
||||
|
||||
if (continueCounter < 0)
|
||||
{
|
||||
setStatusPlaying(PLAYER_STATUS_WAITING);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Le asigna un panel en el marcador al jugador
|
||||
void Player::setScoreBoardPanel(int panel)
|
||||
{
|
||||
scoreBoardPanel = panel;
|
||||
}
|
||||
|
||||
// Obtiene el valor de la variable
|
||||
int Player::getScoreBoardPanel()
|
||||
{
|
||||
return scoreBoardPanel;
|
||||
}
|
||||
Reference in New Issue
Block a user