From 5cd4824c94c91cf0926cfc5ccf0766b003527aee Mon Sep 17 00:00:00 2001 From: Titus Tscharntke Date: Mon, 4 Apr 2011 23:11:59 +0000 Subject: [PATCH] default techtree and map ( if available ) , jpg default for screenshots --- source/g3d_viewer/main.cpp | 2 +- source/glest_game/main/main.cpp | 2 +- .../menu/menu_state_custom_game.cpp | 22 ++++++++++++++----- source/glest_game/menu/menu_state_options.cpp | 2 +- 4 files changed, 20 insertions(+), 8 deletions(-) diff --git a/source/g3d_viewer/main.cpp b/source/g3d_viewer/main.cpp index 4a1eddb3..1cf892ba 100644 --- a/source/g3d_viewer/main.cpp +++ b/source/g3d_viewer/main.cpp @@ -816,7 +816,7 @@ void MainWindow::saveScreenshot() { string path = screenShotsPath; if(isdir(path.c_str()) == true) { Config &config= Config::getInstance(); - string fileFormat = config.getString("ScreenShotFileType","png"); + string fileFormat = config.getString("ScreenShotFileType","jpg"); //string fileFormat = "png"; for(int i=0; i < 5000; ++i) { diff --git a/source/glest_game/main/main.cpp b/source/glest_game/main/main.cpp index 15c5670e..66dfc055 100644 --- a/source/glest_game/main/main.cpp +++ b/source/glest_game/main/main.cpp @@ -789,7 +789,7 @@ void MainWindow::eventKeyDown(char key){ string path = userData + GameConstants::folder_path_screenshots; if(isdir(path.c_str()) == true) { Config &config= Config::getInstance(); - string fileFormat = config.getString("ScreenShotFileType","png"); + string fileFormat = config.getString("ScreenShotFileType","jpg"); unsigned int queueSize = Renderer::getInstance().getSaveScreenQueueSize(); diff --git a/source/glest_game/menu/menu_state_custom_game.cpp b/source/glest_game/menu/menu_state_custom_game.cpp index cd3bbddb..c0da27f4 100644 --- a/source/glest_game/menu/menu_state_custom_game.cpp +++ b/source/glest_game/menu/menu_state_custom_game.cpp @@ -144,6 +144,9 @@ MenuStateCustomGame::MenuStateCustomGame(Program *program, MainMenu *mainMenu, b int networkPos=networkHeadPos-labelOffset; int xoffset=10; + int initialMapSelection=0; + int initialTechSelection=0; + //map listBox // put them all in a set, to weed out duplicates (gbm & mgm with same name) // will also ensure they are alphabetically listed (rather than how the OS provides them) @@ -165,11 +168,13 @@ MenuStateCustomGame::MenuStateCustomGame(Program *program, MainMenu *mainMenu, b copy(playerSortedMaps[0].begin(), playerSortedMaps[0].end(), std::back_inserter(formattedPlayerSortedMaps[0])); std::for_each(formattedPlayerSortedMaps[0].begin(), formattedPlayerSortedMaps[0].end(), FormatString()); - for ( int i = 0 ; i