Compare commits
2 Commits
b5c04c6c26
...
7ea14c984e
| Author | SHA1 | Date | |
|---|---|---|---|
| 7ea14c984e | |||
| bf0171b38d |
@@ -16,7 +16,7 @@ Director::Director(int argc, char *argv[])
|
||||
{
|
||||
// Inicializa variables
|
||||
section = new section_t();
|
||||
section->name = SECTION_PROG_LOGO;
|
||||
section->name = SECTION_PROG_GAME;
|
||||
|
||||
// Inicializa las opciones del programa
|
||||
initOptions();
|
||||
|
||||
133
source/game.cpp
133
source/game.cpp
@@ -27,6 +27,7 @@ Game::Game(int numPlayers, int currentStage, SDL_Renderer *renderer, Screen *scr
|
||||
// Crea los objetos
|
||||
fade = new Fade(renderer);
|
||||
eventHandler = new SDL_Event();
|
||||
scoreboard = new Scoreboard(renderer, screen, asset, lang, options);
|
||||
|
||||
// Carga los recursos
|
||||
loadMedia();
|
||||
@@ -50,7 +51,6 @@ Game::Game(int numPlayers, int currentStage, SDL_Renderer *renderer, Screen *scr
|
||||
|
||||
skyColorsSprite = new Sprite(0, 0, GAMECANVAS_WIDTH, GAMECANVAS_HEIGHT, gameSkyColorsTexture, renderer);
|
||||
grassSprite = new Sprite(0, 0, 256, 6, gameGrassTexture, renderer);
|
||||
powerMeterSprite = new Sprite(PLAY_AREA_CENTER_X - 20, 170, 40, 7, gamePowerMeterTexture, renderer);
|
||||
gameOverSprite = new Sprite(16, 80, 128, 96, gameOverTexture, renderer);
|
||||
gameOverEndSprite = new Sprite(PLAY_AREA_CENTER_X - gameOverEndTexture->getWidth() / 2, 80, 128, 96, gameOverEndTexture, renderer);
|
||||
|
||||
@@ -84,9 +84,6 @@ Game::~Game()
|
||||
gameGrassTexture->unload();
|
||||
delete gameGrassTexture;
|
||||
|
||||
gamePowerMeterTexture->unload();
|
||||
delete gamePowerMeterTexture;
|
||||
|
||||
gameSkyColorsTexture->unload();
|
||||
delete gameSkyColorsTexture;
|
||||
|
||||
@@ -147,9 +144,10 @@ Game::~Game()
|
||||
}
|
||||
balloonTextures.clear();
|
||||
|
||||
delete scoreboard;
|
||||
|
||||
delete text;
|
||||
delete textBig;
|
||||
delete textScoreBoard;
|
||||
delete textNokia2;
|
||||
delete textNokiaBig2;
|
||||
delete gameOverMenu;
|
||||
@@ -167,7 +165,6 @@ Game::~Game()
|
||||
|
||||
delete skyColorsSprite;
|
||||
delete grassSprite;
|
||||
delete powerMeterSprite;
|
||||
delete gameOverSprite;
|
||||
delete gameOverEndSprite;
|
||||
|
||||
@@ -330,7 +327,6 @@ void Game::init()
|
||||
clouds2B->setSpriteClip(0, 52, 256, 32);
|
||||
|
||||
grassSprite->setPosY(154);
|
||||
powerMeterSprite->setSpriteClip(0, 0, 40, 7);
|
||||
|
||||
// Con los globos creados, calcula el nivel de amenaza
|
||||
evaluateAndSetMenace();
|
||||
@@ -401,7 +397,6 @@ void Game::loadMedia()
|
||||
gameBuildingsTexture = new Texture(renderer, asset->get("game_buildings.png"));
|
||||
gameCloudsTexture = new Texture(renderer, asset->get("game_clouds.png"));
|
||||
gameGrassTexture = new Texture(renderer, asset->get("game_grass.png"));
|
||||
gamePowerMeterTexture = new Texture(renderer, asset->get("game_power_meter.png"));
|
||||
gameSkyColorsTexture = new Texture(renderer, asset->get("game_sky_colors.png"));
|
||||
gameTextTexture = new Texture(renderer, asset->get("game_text.png"));
|
||||
gameOverTexture = new Texture(renderer, asset->get("menu_game_over.png"));
|
||||
@@ -540,7 +535,6 @@ void Game::loadMedia()
|
||||
|
||||
// Texto
|
||||
text = new Text(asset->get("smb2.png"), asset->get("smb2.txt"), renderer);
|
||||
textScoreBoard = new Text(asset->get("8bithud.png"), asset->get("8bithud.txt"), renderer);
|
||||
textBig = new Text(asset->get("smb2_big.png"), asset->get("smb2_big.txt"), renderer);
|
||||
textNokia2 = new Text(asset->get("nokia2.png"), asset->get("nokia2.txt"), renderer);
|
||||
textNokiaBig2 = new Text(asset->get("nokia_big2.png"), asset->get("nokia_big2.txt"), renderer);
|
||||
@@ -1599,120 +1593,6 @@ void Game::updateHiScore()
|
||||
}
|
||||
}
|
||||
|
||||
// Transforma un valor numérico en una cadena de 6 cifras
|
||||
std::string Game::updateScoreText(Uint32 num)
|
||||
{
|
||||
if ((num >= 0) && (num <= 9))
|
||||
{
|
||||
return ("000000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 10) && (num <= 99))
|
||||
{
|
||||
return ("00000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 100) && (num <= 999))
|
||||
{
|
||||
return ("0000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 1000) && (num <= 9999))
|
||||
{
|
||||
return ("000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 010000) && (num <= 99999))
|
||||
{
|
||||
return ("00" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 100000) && (num <= 999999))
|
||||
{
|
||||
return ("0" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 1000000) && (num <= 9999999))
|
||||
{
|
||||
return (std::to_string(num));
|
||||
}
|
||||
|
||||
return (std::to_string(num));
|
||||
}
|
||||
|
||||
// Pinta el marcador en pantalla usando un objeto texto
|
||||
void Game::renderScoreBoard()
|
||||
{
|
||||
// Dibuja el fondo del marcador
|
||||
if (difficulty == DIFFICULTY_NORMAL)
|
||||
{ // Pone el color gris de siempre
|
||||
SDL_SetRenderDrawColor(renderer, 46, 63, 71, 255);
|
||||
}
|
||||
else
|
||||
{ // Pinta el fondo del marcador del color de la dificultad
|
||||
SDL_SetRenderDrawColor(renderer, difficultyColor.r, difficultyColor.g, difficultyColor.b, 255);
|
||||
}
|
||||
SDL_Rect rect = {0, 160, 256, 32};
|
||||
SDL_RenderFillRect(renderer, &rect);
|
||||
|
||||
// Dibuja la linea que separa el marcador de la zona de juego
|
||||
SDL_SetRenderDrawColor(renderer, 13, 26, 43, 255);
|
||||
SDL_RenderDrawLine(renderer, 0, 160, 255, 160);
|
||||
|
||||
// Anclas para los elementos
|
||||
const int offset1 = 162;
|
||||
const int offset2 = offset1 + 7;
|
||||
const int offset3 = offset2 + 7;
|
||||
const int offset4 = offset3 + 7;
|
||||
|
||||
const int offsetLeft = PLAY_AREA_LEFT + 45;
|
||||
const int offsetRight = PLAY_AREA_RIGHT - 45;
|
||||
|
||||
// PLAYER1 - SCORE
|
||||
textScoreBoard->writeCentered(offsetLeft, offset1, lang->getText(53));
|
||||
textScoreBoard->writeCentered(offsetLeft, offset2, updateScoreText(players[0]->getScore()));
|
||||
|
||||
// PLAYER1 - MULT
|
||||
textScoreBoard->writeCentered(offsetLeft, offset3, lang->getText(55));
|
||||
textScoreBoard->writeCentered(offsetLeft, offset4, std::to_string(players[0]->getScoreMultiplier()).substr(0, 3));
|
||||
|
||||
if (numPlayers == 2)
|
||||
{
|
||||
// PLAYER2 - SCORE
|
||||
textScoreBoard->writeCentered(offsetRight, offset1, lang->getText(54));
|
||||
textScoreBoard->writeCentered(offsetRight, offset2, updateScoreText(players[1]->getScore()));
|
||||
|
||||
// PLAYER2 - MULT
|
||||
textScoreBoard->writeCentered(offsetRight, offset3, lang->getText(55));
|
||||
textScoreBoard->writeCentered(offsetRight, offset4, std::to_string(players[1]->getScoreMultiplier()).substr(0, 3));
|
||||
}
|
||||
else
|
||||
{
|
||||
// PLAYER2 - SCORE
|
||||
textScoreBoard->writeCentered(offsetRight, offset1, lang->getText(54));
|
||||
textScoreBoard->writeCentered(offsetRight, offset2, "0000000");
|
||||
|
||||
// PLAYER2 - MULT
|
||||
textScoreBoard->writeCentered(offsetRight, offset3, lang->getText(55));
|
||||
textScoreBoard->writeCentered(offsetRight, offset4, "1.0");
|
||||
}
|
||||
|
||||
// STAGE
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset1, lang->getText(57) + std::to_string(stage[currentStage].number));
|
||||
|
||||
// POWERMETER
|
||||
powerMeterSprite->setPosY(offset2);
|
||||
powerMeterSprite->setSpriteClip(0, 0, 40, 7);
|
||||
powerMeterSprite->render();
|
||||
const float percent = (stage[currentStage].currentPower * 40.0f) / stage[currentStage].powerToComplete;
|
||||
powerMeterSprite->setSpriteClip(40, 0, (int)percent, 7);
|
||||
powerMeterSprite->render();
|
||||
|
||||
// HI-SCORE
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset3, lang->getText(56));
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset4, hiScoreName + updateScoreText(hiScore));
|
||||
}
|
||||
|
||||
// Actualiza las variables del jugador
|
||||
void Game::updatePlayers()
|
||||
{
|
||||
@@ -2928,7 +2808,7 @@ void Game::render()
|
||||
renderMessages();
|
||||
renderItems();
|
||||
renderSmartSprites();
|
||||
renderScoreBoard();
|
||||
scoreboard->render();
|
||||
renderPlayers();
|
||||
|
||||
if ((deathCounter <= 150) && !players[0]->isAlive())
|
||||
@@ -3292,7 +3172,7 @@ void Game::shakeScreen()
|
||||
renderBullets();
|
||||
renderItems();
|
||||
renderPlayers();
|
||||
renderScoreBoard();
|
||||
scoreboard->render();
|
||||
|
||||
// Vuelca el contenido del renderizador en pantalla
|
||||
screen->blit();
|
||||
@@ -3433,7 +3313,7 @@ void Game::renderPausedGame()
|
||||
renderMessages();
|
||||
renderItems();
|
||||
renderSmartSprites();
|
||||
renderScoreBoard();
|
||||
scoreboard->render();
|
||||
renderPlayers();
|
||||
|
||||
if ((deathCounter <= 150) && !players[0]->isAlive())
|
||||
@@ -3916,7 +3796,6 @@ void Game::reloadTextures()
|
||||
gameBuildingsTexture->reLoad();
|
||||
gameCloudsTexture->reLoad();
|
||||
gameGrassTexture->reLoad();
|
||||
gamePowerMeterTexture->reLoad();
|
||||
gameSkyColorsTexture->reLoad();
|
||||
gameTextTexture->reLoad();
|
||||
}
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
#include "fade.h"
|
||||
#include "item.h"
|
||||
#include "player.h"
|
||||
#include "scoreboard.h"
|
||||
#include <iostream>
|
||||
|
||||
#ifndef GAME_H
|
||||
@@ -121,6 +122,7 @@ private:
|
||||
Lang *lang; // Objeto para gestionar los textos en diferentes idiomas
|
||||
Input *input; // Manejador de entrada
|
||||
section_t *section; // Seccion actual dentro del juego
|
||||
Scoreboard *scoreboard; // Objeto para dibujar el marcador
|
||||
|
||||
std::vector<Player *> players; // Vector con los jugadores
|
||||
std::vector<Balloon *> balloons; // Vector con los globos
|
||||
@@ -138,7 +140,6 @@ private:
|
||||
Texture *gameBuildingsTexture; // Textura con los edificios de fondo
|
||||
Texture *gameCloudsTexture; // Textura con las nubes de fondo
|
||||
Texture *gameGrassTexture; // Textura con la hierba del suelo
|
||||
Texture *gamePowerMeterTexture; // Textura con el marcador de poder de la fase
|
||||
Texture *gameSkyColorsTexture; // Textura con los diferentes colores de fondo del juego
|
||||
Texture *gameTextTexture; // Textura para los sprites con textos
|
||||
Texture *gameOverTexture; // Textura para la pantalla de game over
|
||||
@@ -150,7 +151,6 @@ private:
|
||||
|
||||
Text *text; // Fuente para los textos del juego
|
||||
Text *textBig; // Fuente de texto grande
|
||||
Text *textScoreBoard; // Fuente para el marcador del juego
|
||||
Text *textNokia2; // Otra fuente de texto para mensajes
|
||||
Text *textNokiaBig2; // Y la versión en grande
|
||||
|
||||
@@ -171,7 +171,6 @@ private:
|
||||
Sprite *buildingsSprite; // Sprite con los edificios de fondo
|
||||
Sprite *skyColorsSprite; // Sprite con los graficos del degradado de color de fondo
|
||||
Sprite *grassSprite; // Sprite para la hierba
|
||||
Sprite *powerMeterSprite; // Sprite para el medidor de poder de la fase
|
||||
Sprite *gameOverSprite; // Sprite para dibujar los graficos del game over
|
||||
Sprite *gameOverEndSprite; // Sprite para dibujar los graficos del game over de acabar el juego
|
||||
|
||||
@@ -287,12 +286,6 @@ private:
|
||||
// Actualiza el valor de HiScore en caso necesario
|
||||
void updateHiScore();
|
||||
|
||||
// Transforma un valor numérico en una cadena de 6 cifras
|
||||
std::string updateScoreText(Uint32 num);
|
||||
|
||||
// Pinta el marcador en pantalla usando un objeto texto
|
||||
void renderScoreBoard();
|
||||
|
||||
// Actualiza las variables del jugador
|
||||
void updatePlayers();
|
||||
|
||||
|
||||
176
source/scoreboard.cpp
Normal file
176
source/scoreboard.cpp
Normal file
@@ -0,0 +1,176 @@
|
||||
#include "scoreboard.h"
|
||||
|
||||
// Constructor
|
||||
Scoreboard::Scoreboard(SDL_Renderer *renderer, Screen *screen, Asset *asset, Lang *lang, options_t *options)
|
||||
{
|
||||
// Copia los punteros
|
||||
this->renderer = renderer;
|
||||
this->screen = screen;
|
||||
this->asset = asset;
|
||||
this->lang = lang;
|
||||
this->options = options;
|
||||
|
||||
// Crea objetos
|
||||
gamePowerMeterTexture = new Texture(renderer, asset->get("game_power_meter.png"));
|
||||
powerMeterSprite = new Sprite(PLAY_AREA_CENTER_X - 20, 170, 40, 7, gamePowerMeterTexture, renderer);
|
||||
textScoreBoard = new Text(asset->get("8bithud.png"), asset->get("8bithud.txt"), renderer);
|
||||
|
||||
// Inicializa variables
|
||||
stage = 0;
|
||||
score1 = 0;
|
||||
score2 = 0;
|
||||
mult1 = 0;
|
||||
mult2 = 0;
|
||||
hiScore = 0;
|
||||
power = 0;
|
||||
hiScoreName = "";
|
||||
color = {255, 0, 0};
|
||||
}
|
||||
|
||||
Scoreboard::~Scoreboard()
|
||||
{
|
||||
gamePowerMeterTexture->unload();
|
||||
delete gamePowerMeterTexture;
|
||||
delete powerMeterSprite;
|
||||
delete textScoreBoard;
|
||||
}
|
||||
|
||||
// Transforma un valor numérico en una cadena de 6 cifras
|
||||
std::string Scoreboard::updateScoreText(Uint32 num)
|
||||
{
|
||||
if ((num >= 0) && (num <= 9))
|
||||
{
|
||||
return ("000000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 10) && (num <= 99))
|
||||
{
|
||||
return ("00000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 100) && (num <= 999))
|
||||
{
|
||||
return ("0000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 1000) && (num <= 9999))
|
||||
{
|
||||
return ("000" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 010000) && (num <= 99999))
|
||||
{
|
||||
return ("00" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 100000) && (num <= 999999))
|
||||
{
|
||||
return ("0" + std::to_string(num));
|
||||
}
|
||||
|
||||
if ((num >= 1000000) && (num <= 9999999))
|
||||
{
|
||||
return (std::to_string(num));
|
||||
}
|
||||
|
||||
return (std::to_string(num));
|
||||
}
|
||||
|
||||
// Pinta el marcador
|
||||
void Scoreboard::render()
|
||||
{
|
||||
// Dibuja el fondo del marcador
|
||||
SDL_SetRenderDrawColor(renderer, color.r, color.g, color.b, 255);
|
||||
SDL_Rect rect = {0, 160, 256, 32};
|
||||
SDL_RenderFillRect(renderer, &rect);
|
||||
|
||||
// Dibuja la linea que separa el marcador de la zona de juego
|
||||
SDL_SetRenderDrawColor(renderer, 13, 26, 43, 255);
|
||||
SDL_RenderDrawLine(renderer, 0, 160, 255, 160);
|
||||
|
||||
// Anclas para los elementos
|
||||
const int offset1 = 162;
|
||||
const int offset2 = offset1 + 7;
|
||||
const int offset3 = offset2 + 7;
|
||||
const int offset4 = offset3 + 7;
|
||||
|
||||
const int offsetLeft = PLAY_AREA_LEFT + 45;
|
||||
const int offsetRight = PLAY_AREA_RIGHT - 45;
|
||||
|
||||
// PLAYER1 - SCORE
|
||||
textScoreBoard->writeCentered(offsetLeft, offset1, lang->getText(53));
|
||||
textScoreBoard->writeCentered(offsetLeft, offset2, updateScoreText(score1));
|
||||
|
||||
// PLAYER1 - MULT
|
||||
textScoreBoard->writeCentered(offsetLeft, offset3, lang->getText(55));
|
||||
textScoreBoard->writeCentered(offsetLeft, offset4, std::to_string(mult1).substr(0, 3));
|
||||
|
||||
// PLAYER2 - SCORE
|
||||
textScoreBoard->writeCentered(offsetRight, offset1, lang->getText(54));
|
||||
textScoreBoard->writeCentered(offsetRight, offset2, updateScoreText(score2));
|
||||
|
||||
// PLAYER2 - MULT
|
||||
textScoreBoard->writeCentered(offsetRight, offset3, lang->getText(55));
|
||||
textScoreBoard->writeCentered(offsetRight, offset4, std::to_string(mult2).substr(0, 3));
|
||||
|
||||
// STAGE
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset1, lang->getText(57) + std::to_string(stage));
|
||||
|
||||
// POWERMETER
|
||||
powerMeterSprite->setPosY(offset2);
|
||||
powerMeterSprite->setSpriteClip(0, 0, 40, 7);
|
||||
powerMeterSprite->render();
|
||||
// const float percent = (stage[currentStage].currentPower * 40.0f) / stage[currentStage].powerToComplete;
|
||||
const float percent = 0.5;
|
||||
powerMeterSprite->setSpriteClip(40, 0, (int)percent, 7);
|
||||
powerMeterSprite->render();
|
||||
|
||||
// HI-SCORE
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset3, lang->getText(56));
|
||||
textScoreBoard->writeCentered(PLAY_AREA_CENTER_X, offset4, hiScoreName + updateScoreText(hiScore));
|
||||
}
|
||||
|
||||
void Scoreboard::setScore1(int score)
|
||||
{
|
||||
score1 = score;
|
||||
}
|
||||
|
||||
void Scoreboard::setScore2(int score)
|
||||
{
|
||||
score2 = score;
|
||||
}
|
||||
|
||||
void Scoreboard::setMult1(int mult)
|
||||
{
|
||||
mult1 = mult;
|
||||
}
|
||||
|
||||
void Scoreboard::setMult2(int mult)
|
||||
{
|
||||
mult2 = mult;
|
||||
}
|
||||
|
||||
void Scoreboard::setStage(int stage)
|
||||
{
|
||||
this->stage = stage;
|
||||
}
|
||||
|
||||
void Scoreboard::setHiScore(int hiScore)
|
||||
{
|
||||
this->hiScore = hiScore;
|
||||
}
|
||||
|
||||
void Scoreboard::setPower(int power)
|
||||
{
|
||||
this->power = power;
|
||||
}
|
||||
|
||||
void Scoreboard::setHiScoreName(std::string name)
|
||||
{
|
||||
hiScoreName = name;
|
||||
}
|
||||
|
||||
void Scoreboard::setColor(color_t color)
|
||||
{
|
||||
this->color = color;
|
||||
}
|
||||
71
source/scoreboard.h
Normal file
71
source/scoreboard.h
Normal file
@@ -0,0 +1,71 @@
|
||||
#pragma once
|
||||
|
||||
#include <SDL2/SDL.h>
|
||||
#include "common/asset.h"
|
||||
#include "common/input.h"
|
||||
#include "common/jail_audio.h"
|
||||
#include "common/menu.h"
|
||||
#include "common/movingsprite.h"
|
||||
#include "common/screen.h"
|
||||
#include "common/smartsprite.h"
|
||||
#include "common/sprite.h"
|
||||
#include "common/text.h"
|
||||
#include "common/utils.h"
|
||||
#include "common/writer.h"
|
||||
#include "const.h"
|
||||
|
||||
#ifndef SCOREBOARD_H
|
||||
#define SCOREBOARD_H
|
||||
|
||||
// Clase Scoreboard
|
||||
class Scoreboard
|
||||
{
|
||||
private:
|
||||
// Objetos y punteros
|
||||
SDL_Renderer *renderer; // El renderizador de la ventana
|
||||
Screen *screen; // Objeto encargado de dibujar en pantalla
|
||||
Asset *asset; // Objeto que gestiona todos los ficheros de recursos
|
||||
Lang *lang; // Objeto para gestionar los textos en diferentes idiomas
|
||||
|
||||
Texture *gamePowerMeterTexture; // Textura con el marcador de poder de la fase
|
||||
Sprite *powerMeterSprite; // Sprite para el medidor de poder de la fase
|
||||
Text *textScoreBoard; // Fuente para el marcador del juego
|
||||
|
||||
// Variables
|
||||
struct options_t *options; // Variable con todas las variables de las opciones del programa
|
||||
int stage; // Numero de fase actual
|
||||
int score1; // Puntuación del jugador 1
|
||||
int score2; // Puntuación del jugador 2
|
||||
int mult1; // Multiplicador del jugador 1
|
||||
int mult2; // MUltiplicador del jugador 2
|
||||
int hiScore; // Mäxima puntuación
|
||||
int power; // Poder actual de la fase
|
||||
std::string hiScoreName; // Nombre del jugador con la máxima puntuación
|
||||
color_t color; // Color del marcador
|
||||
|
||||
public:
|
||||
// Constructor
|
||||
Scoreboard(SDL_Renderer *renderer, Screen *screen, Asset *asset, Lang *lang, options_t *options);
|
||||
|
||||
// Destructor
|
||||
~Scoreboard();
|
||||
|
||||
// Pinta el marcador
|
||||
void render();
|
||||
|
||||
void setScore1(int score);
|
||||
void setScore2(int score);
|
||||
void setMult1(int mult);
|
||||
void setMult2(int mult);
|
||||
void setStage(int stage);
|
||||
void setHiScore(int hiScore);
|
||||
void setPower(int power);
|
||||
void setHiScoreName(std::string name);
|
||||
void setColor(color_t color);
|
||||
|
||||
private:
|
||||
// Transforma un valor numérico en una cadena de 6 cifras
|
||||
std::string updateScoreText(Uint32 num);
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user