Tweaked button graphics

This commit is contained in:
2015-12-25 22:53:05 +11:00
parent e6e2421ba0
commit fe7bbbbb3d
9 changed files with 39 additions and 20 deletions
+2 -2
View File
@@ -37,7 +37,7 @@ DisconnectedScreen::DisconnectedScreen() {
//setup the utility objects
//TODO: (1) resource tool, to prevent reloading like this
image.Load(GetRenderer(), config["dir.interface"] + "button_red.png");
image.Load(GetRenderer(), config["dir.interface"] + "button_blue.png");
font = TTF_OpenFont(config["client.font"].c_str(), 12);
//check that the font loaded
@@ -49,7 +49,7 @@ DisconnectedScreen::DisconnectedScreen() {
//setup the button
backButton.SetBackgroundTexture(GetRenderer(), image.GetTexture());
backButton.SetText(GetRenderer(), font, "Back", COLOR_BLUE);
backButton.SetText(GetRenderer(), font, "Back", COLOR_WHITE);
//set the button positions
backButton.SetX(50);
+4 -4
View File
@@ -40,7 +40,7 @@ LobbyMenu::LobbyMenu(int* const argClientIndex, int* const argAccountIndex):
accountIndex = -1;
//setup the utility objects
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_red.png");
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_blue.png");
font = TTF_OpenFont(config["client.font"].c_str(), 12);
//check that the font loaded
@@ -52,11 +52,11 @@ LobbyMenu::LobbyMenu(int* const argClientIndex, int* const argAccountIndex):
//setup the buttons
searchButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
searchButton.SetText(GetRenderer(), font, "Search", COLOR_BLUE);
searchButton.SetText(GetRenderer(), font, "Search", COLOR_WHITE);
joinButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
joinButton.SetText(GetRenderer(), font, "Join", COLOR_BLUE);
joinButton.SetText(GetRenderer(), font, "Join", COLOR_WHITE);
backButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
backButton.SetText(GetRenderer(), font, "Back", COLOR_BLUE);
backButton.SetText(GetRenderer(), font, "Back", COLOR_WHITE);
//set the button positions (assumed)
searchButton.SetX(50);
+4 -4
View File
@@ -34,7 +34,7 @@ MainMenu::MainMenu() {
ConfigUtility& config = ConfigUtility::GetSingleton();
//setup the utility objects
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_red.png");
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_blue.png");
font = TTF_OpenFont(config["client.font"].c_str(), 12);
//check that the font loaded
@@ -46,11 +46,11 @@ MainMenu::MainMenu() {
//setup the buttons
startButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
startButton.SetText(GetRenderer(), font, "Start", COLOR_BLUE);
startButton.SetText(GetRenderer(), font, "Start", COLOR_WHITE);
optionsButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
optionsButton.SetText(GetRenderer(), font, "Options", COLOR_BLUE);
optionsButton.SetText(GetRenderer(), font, "Options", COLOR_WHITE);
quitButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
quitButton.SetText(GetRenderer(), font, "Quit", COLOR_BLUE);
quitButton.SetText(GetRenderer(), font, "Quit", COLOR_WHITE);
//set the button positions
startButton.SetX(50);
+2 -2
View File
@@ -34,7 +34,7 @@ OptionsMenu::OptionsMenu() {
ConfigUtility& config = ConfigUtility::GetSingleton();
//setup the utility objects
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_red.png");
buttonImage.Load(GetRenderer(), config["dir.interface"] + "button_blue.png");
font = TTF_OpenFont(config["client.font"].c_str(), 12);
//check that the font loaded
@@ -46,7 +46,7 @@ OptionsMenu::OptionsMenu() {
//setup the button
backButton.SetBackgroundTexture(GetRenderer(), buttonImage.GetTexture());
backButton.SetText(GetRenderer(), font, "Back", COLOR_BLUE);
backButton.SetText(GetRenderer(), font, "Back", COLOR_WHITE);
//set the button positions
backButton.SetX(50);