La sección del título se termina al pasar cierto tiempo, no cuando se termina la marquesina
This commit is contained in:
@@ -119,6 +119,7 @@ void Title::checkEvents()
|
|||||||
|
|
||||||
case SDL_SCANCODE_3:
|
case SDL_SCANCODE_3:
|
||||||
runEnterID();
|
runEnterID();
|
||||||
|
counter = 0;
|
||||||
cheevos->reload();
|
cheevos->reload();
|
||||||
fillTexture();
|
fillTexture();
|
||||||
createCheevosTexture();
|
createCheevosTexture();
|
||||||
@@ -150,9 +151,14 @@ void Title::checkInput()
|
|||||||
if (input->checkInput(input_exit, REPEAT_FALSE))
|
if (input->checkInput(input_exit, REPEAT_FALSE))
|
||||||
{
|
{
|
||||||
if (showCheevos)
|
if (showCheevos)
|
||||||
|
{
|
||||||
hideCheevosList();
|
hideCheevosList();
|
||||||
|
counter = 0;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
section->name = SECTION_PROG_QUIT;
|
section->name = SECTION_PROG_QUIT;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
else if (input->checkInput(input_toggle_border, REPEAT_FALSE))
|
else if (input->checkInput(input_toggle_border, REPEAT_FALSE))
|
||||||
@@ -216,6 +222,12 @@ void Title::updateMarquee()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Comprueba si ha terminado la marquesina y la reinicia
|
||||||
|
if (letters[letters.size() - 1].x < -10)
|
||||||
|
{ // Inicializa la marquesina
|
||||||
|
initMarquee();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Dibuja la marquesina
|
// Dibuja la marquesina
|
||||||
@@ -261,19 +273,14 @@ void Title::update()
|
|||||||
// Actualiza las notificaciones
|
// Actualiza las notificaciones
|
||||||
screen->updateNotifier();
|
screen->updateNotifier();
|
||||||
|
|
||||||
// Comprueba si ha terminado la marquesina y acaba con el titulo
|
// Si el contador alcanza cierto valor, termina la seccion
|
||||||
if (letters[letters.size() - 1].x < -10)
|
if (counter == 2200)
|
||||||
{
|
{
|
||||||
if (!showCheevos)
|
if (!showCheevos)
|
||||||
{
|
{
|
||||||
section->name = SECTION_PROG_CREDITS;
|
section->name = SECTION_PROG_CREDITS;
|
||||||
section->subsection = 0;
|
section->subsection = 0;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
// Inicializa la marquesina
|
|
||||||
initMarquee();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user