From ca10bd5776bfb1187bfc3d869a7ef7b3586c2b5a Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Tue, 20 Apr 2010 23:23:06 +0000 Subject: [PATCH 1/7] Bugfixes for 3.3.4 defects found: - Fog of War always turned off in scenarios and tutorials - memory cleanup in join menu - removed dsound.dll copying from batch file --- mk/windoze/CopyWindowsRuntimeDlls.bat | 2 +- mk/windoze/Glest.suo | Bin 194048 -> 194048 bytes source/glest_game/facilities/game_util.cpp | 2 +- source/glest_game/game/game_settings.h | 4 +++- .../glest_game/menu/menu_state_join_game.cpp | 1 + 5 files changed, 6 insertions(+), 3 deletions(-) diff --git a/mk/windoze/CopyWindowsRuntimeDlls.bat b/mk/windoze/CopyWindowsRuntimeDlls.bat index c54532e69..4b59dafb1 100644 --- a/mk/windoze/CopyWindowsRuntimeDlls.bat +++ b/mk/windoze/CopyWindowsRuntimeDlls.bat @@ -1,6 +1,6 @@ @echo off -if not exist ..\..\data\glest_game\dsound.dll copy dsound.dll ..\..\data\glest_game\ +rem if not exist ..\..\data\glest_game\dsound.dll copy dsound.dll ..\..\data\glest_game\ if not exist ..\..\data\glest_game\xerces-c_3_0.dll copy xerces-c_3_0.dll ..\..\data\glest_game\ if not exist ..\..\data\glest_game\libpng14.dll copy libpng14.dll ..\..\data\glest_game\ if not exist ..\..\data\glest_game\zlib1.dll copy zlib1.dll ..\..\data\glest_game\ diff --git a/mk/windoze/Glest.suo b/mk/windoze/Glest.suo index c6253989474a84fe2c1b13199dbe27612a39e20e..f96dd9f3cd55c4de1cdbcf1ff7f2aa046a9ce869 100755 GIT binary patch delta 5794 zcmbVQ3sh8BmVM_|6%_Bq$}RgmkeppG(aaNCrrjhA{(f<{pkS0S#}p440Twx2I@)`?j3>9wAE zok6Q9R}}27du&{xQl%6q$AwQJ-~weA|Pof-*5ZFu`*(XqNC({JG6pOJ4bE1p|M zJxmTz02C#XTM`&1#+d_2rW-$f-7ni8;pedoDU*BK<#I;ZSC;YrI%SDc?)h+p4s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SWx#xsmLj6B9HhIFX83^T*RSi+!mm6#b;&QJ0Z zw3PqKUu%{#R>(2>y-Li1Uz*EDcdCVL!o5Ha;ypj++WCXJN}iB$HZ)-Uc+4;ek8M1E zfj<<@a}PO5Wr$7XrQ|dRVv6X~sN5I*k5xath$s?G}kRj;$scZfJ0UPo_L;wH) diff --git a/source/glest_game/facilities/game_util.cpp b/source/glest_game/facilities/game_util.cpp index 309620373..7139f60b0 100644 --- a/source/glest_game/facilities/game_util.cpp +++ b/source/glest_game/facilities/game_util.cpp @@ -25,7 +25,7 @@ using namespace Shared::Platform; namespace Glest{ namespace Game{ const string mailString= "contact_game@glest.org"; -const string glestVersionString= "v3.3.4"; +const string glestVersionString= "v3.3.4.1"; string getCrashDumpFileName(){ return "glest"+glestVersionString+".dmp"; diff --git a/source/glest_game/game/game_settings.h b/source/glest_game/game/game_settings.h index 84f2c03fd..c3f64f8b3 100644 --- a/source/glest_game/game/game_settings.h +++ b/source/glest_game/game/game_settings.h @@ -46,7 +46,9 @@ private: public: - GameSettings() { } + GameSettings() { + fogOfWar = true; + } // default copy constructor will do fine, and will maintain itself ;) diff --git a/source/glest_game/menu/menu_state_join_game.cpp b/source/glest_game/menu/menu_state_join_game.cpp index 6c7eb8775..c0d1a7dbb 100644 --- a/source/glest_game/menu/menu_state_join_game.cpp +++ b/source/glest_game/menu/menu_state_join_game.cpp @@ -43,6 +43,7 @@ MenuStateJoinGame::MenuStateJoinGame(Program *program, MainMenu *mainMenu, bool Lang &lang= Lang::getInstance(); Config &config= Config::getInstance(); NetworkManager &networkManager= NetworkManager::getInstance(); + networkManager.end(); serversSavedFile = serverFileName; if(getGameReadWritePath() != "") { From dd704fe3721c6258e8b95631f54e473dac1de94b Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Wed, 21 Apr 2010 00:59:53 +0000 Subject: [PATCH 2/7] Updated version # and startup script for 3.3.4.1 release --- mk/linux/configure.ac | 2 +- mk/linux/glest | 81 +++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 79 insertions(+), 4 deletions(-) diff --git a/mk/linux/configure.ac b/mk/linux/configure.ac index 959f5b6cb..9a6e5e9e0 100644 --- a/mk/linux/configure.ac +++ b/mk/linux/configure.ac @@ -4,7 +4,7 @@ #---------------------------------------------------------------------------- AC_PREREQ([2.54]) -AC_INIT([megaglest], [3.3.4], [matze@braunis.de]) +AC_INIT([megaglest], [3.3.4.1], [matze@braunis.de]) AC_CONFIG_SRCDIR([mk/jam/build.jam]) AC_CONFIG_AUX_DIR([mk/autoconf]) diff --git a/mk/linux/glest b/mk/linux/glest index 5ac029800..ab93acda4 100755 --- a/mk/linux/glest +++ b/mk/linux/glest @@ -20,16 +20,91 @@ cd $GAMEDIR test -n "${LIBDIR}" && export LD_LIBRARY_PATH="${LD_LIBRARY_PATH}:${GAMEDIR}/${LIBDIR}" # now deal with the openal library [libopenal.so.0] -hasopenal=`ldconfig -p | grep -m 1 "libopenal.so.0" | cut "-d>" -f2 | cut "-d " -f2` +OSTYPE=`uname -m` + +OPENAL_LINKEDLIBNAME="libopenal.so.0" +OPENAL_LIBLOOKUP1=${OPENAL_LINKEDLIBNAME} +OPENAL_LIBLOOKUP2="libopenal.so.1" + +DIRECTFB_LINKEDLIBNAME="libdirectfb-1.0.so.0" +DIRECTFB_LIBLOOKUP1=${DIRECTFB_LINKEDLIBNAME} +DIRECTFB_LIBLOOKUP2="libdirectfb-1.2.so.0" + +FUSION_LINKEDLIBNAME="libfusion-1.0.so.0" +FUSION_LIBLOOKUP1=${DIRECTFB_LINKEDLIBNAME} +FUSION_LIBLOOKUP2="libfusion-1.2.so.0" + +DIRECT_LINKEDLIBNAME="libdirect-1.0.so.0" +DIRECT_LIBLOOKUP1=${DIRECT_LINKEDLIBNAME} +DIRECT_LIBLOOKUP2="libdirect-1.2.so.0" + +if [ "$OSTYPE" = "x86_64" ]; then + OPENAL_LIBLOOKUP1="${OPENAL_LIBLOOKUP1} (libc6)" + OPENAL_LIBLOOKUP2="${OPENAL_LIBLOOKUP2} (libc6)" + + DIRECTFB_LIBLOOKUP1="${DIRECTFB_LIBLOOKUP1} (libc6)" + DIRECTFB_LIBLOOKUP2="${DIRECTFB_LIBLOOKUP2} (libc6)" + + FUSION_LIBLOOKUP1="${FUSION_LIBLOOKUP1} (libc6)" + FUSION_LIBLOOKUP2="${FUSION_LIBLOOKUP2} (libc6)" + + DIRECT_LIBLOOKUP1="${DIRECT_LIBLOOKUP1} (libc6)" + DIRECT_LIBLOOKUP2="${DIRECT_LIBLOOKUP2} (libc6)" +fi + +hasopenal=`ldconfig -p | grep -m 1 "$OPENAL_LIBLOOKUP1" | cut "-d>" -f2 | cut "-d " -f2` #echo "openal search = [$hasopenal]" if [ -n "$hasopenal" ]; then echo "default openal library was found in [$hasopenal]" else echo "default openal library is missing, attempting to find and link to a newer version if available..." - hasopenal=`ldconfig -p | grep -m 1 "libopenal.so.1" | cut "-d>" -f2 | cut "-d " -f2` + hasopenal=`ldconfig -p | grep -m 1 "$OPENAL_LIBLOOKUP2" | cut "-d>" -f2 | cut "-d " -f2` if [ -n "$hasopenal" ]; then - ln -f -s $hasopenal lib/libopenal.so.0 + echo "new openal library link = $hasopenal" + ln -f -s $hasopenal lib/${OPENAL_LINKEDLIBNAME} + fi +fi + +hasdirectfb=`ldconfig -p | grep -m 1 "$DIRECTFB_LIBLOOKUP1" | cut "-d>" -f2 | cut "-d " -f2` +#echo "directfb search = [$hasdirectfb]" +if [ -n "$hasdirectfb" ]; then + echo "default directfb library was found in [$hasdirectfb]" +else + echo "default directfb library is missing, attempting to find and link to a different location if available..." + + hasdirectfb=`ldconfig -p | grep -m 1 "$DIRECTFB_LIBLOOKUP2" | cut "-d>" -f2 | cut "-d " -f2` + if [ -n "$hasdirectfb" ]; then + echo "new directfb library link = $hasdirectfb" + ln -f -s $hasdirectfb lib/${DIRECTFB_LINKEDLIBNAME} + fi +fi + +hasfusion=`ldconfig -p | grep -m 1 "$FUSION_LIBLOOKUP1" | cut "-d>" -f2 | cut "-d " -f2` +#echo "fusion search = [$hasfusion]" +if [ -n "$hasfusion" ]; then + echo "default fusion library was found in [$hasfusion]" +else + echo "default fusion library is missing, attempting to find and link to a different location if available..." + + hasfusion=`ldconfig -p | grep -m 1 "$FUSION_LIBLOOKUP2" | cut "-d>" -f2 | cut "-d " -f2` + if [ -n "$hasfusion" ]; then + echo "new fusion library link = $hasfusion" + ln -f -s $hasfusion lib/${FUSION_LINKEDLIBNAME} + fi +fi + +hasdirect=`ldconfig -p | grep -m 1 "$DIRECT_LIBLOOKUP1" | cut "-d>" -f2 | cut "-d " -f2` +#echo "direct search = [$hasdirect]" +if [ -n "$hasdirect" ]; then + echo "default direct library was found in [$hasdirect]" +else + echo "default direct library is missing, attempting to find and link to a different location if available..." + + hasdirect=`ldconfig -p | grep -m 1 "$DIRECT_LIBLOOKUP2" | cut "-d>" -f2 | cut "-d " -f2` + if [ -n "$hasdirect" ]; then + echo "new direct library link = $hasdirect" + ln -f -s $hasdirect lib/${DIRECT_LINKEDLIBNAME} fi fi From a01c0adb78044e3a744f773234cfd7ac2e8bddc5 Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Fri, 23 Apr 2010 02:48:56 +0000 Subject: [PATCH 3/7] Added a new lua script function called: unfogMap to allow scenarios and tutorials to turn off fog of war. --- source/glest_game/game/script_manager.cpp | 13 ++++++++++++- source/glest_game/game/script_manager.h | 6 +++--- source/glest_game/world/world.cpp | 18 +++++++++++++++++- source/glest_game/world/world.h | 5 ++++- 4 files changed, 36 insertions(+), 6 deletions(-) diff --git a/source/glest_game/game/script_manager.cpp b/source/glest_game/game/script_manager.cpp index 4d5a2a991..d2bd87ac1 100644 --- a/source/glest_game/game/script_manager.cpp +++ b/source/glest_game/game/script_manager.cpp @@ -1,7 +1,7 @@ // ============================================================== // This file is part of Glest (www.glest.org) // -// Copyright (C) 2001-2005 Martiņo Figueroa +// Copyright (C) 2001-2005 Martio Figueroa // // You can redistribute this code and/or modify it under // the terms of the GNU General Public License as published @@ -71,6 +71,7 @@ void ScriptManager::init(World* world, GameCamera *gameCamera){ luaScript.registerFunction(getLastDeadUnitId, "lastDeadUnit"); luaScript.registerFunction(getUnitCount, "unitCount"); luaScript.registerFunction(getUnitCountOfType, "unitCountOfType"); + luaScript.registerFunction(unfogMap, "unfogMap"); //load code @@ -396,4 +397,14 @@ int ScriptManager::getUnitCountOfType(LuaHandle* luaHandle){ return luaArguments.getReturnCount(); } +void ScriptManager::unfogMap() { + world->setFogOfWar(false); +} + +int ScriptManager::unfogMap(LuaHandle* luaHandle){ + LuaArguments luaArguments(luaHandle); + thisScriptManager->unfogMap(); + return luaArguments.getReturnCount(); +} + }}//end namespace diff --git a/source/glest_game/game/script_manager.h b/source/glest_game/game/script_manager.h index ae896404f..dbb197650 100644 --- a/source/glest_game/game/script_manager.h +++ b/source/glest_game/game/script_manager.h @@ -1,7 +1,7 @@ // ============================================================== // This file is part of Glest (www.glest.org) // -// Copyright (C) 2001-2005 Martiņo Figueroa +// Copyright (C) 2001-2005 Martio Figueroa // // You can redistribute this code and/or modify it under // the terms of the GNU General Public License as published @@ -16,7 +16,6 @@ #include #include "lua_script.h" -#include "vec.h" #include "components.h" #include "game_constants.h" @@ -122,7 +121,6 @@ public: void onUnitDied(const Unit* unit); private: - string wrapString(const string &str, int wrapCount); //wrappers, commands @@ -138,6 +136,7 @@ private: void disableAi(int factionIndex); void setPlayerAsWinner(int factionIndex); void endGame(); + void unfogMap(); //wrappers, queries Vec2i getStartLocation(int factionIndex); @@ -164,6 +163,7 @@ private: static int disableAi(LuaHandle* luaHandle); static int setPlayerAsWinner(LuaHandle* luaHandle); static int endGame(LuaHandle* luaHandle); + static int unfogMap(LuaHandle* luaHandle); //callbacks, queries static int getStartLocation(LuaHandle* luaHandle); diff --git a/source/glest_game/world/world.cpp b/source/glest_game/world/world.cpp index 4af26c507..14dffef14 100644 --- a/source/glest_game/world/world.cpp +++ b/source/glest_game/world/world.cpp @@ -39,6 +39,8 @@ const float World::airHeight= 5.f; World::World(){ Config &config= Config::getInstance(); + fogOfWarOverride = false; + fogOfWarSmoothing= config.getBool("FogOfWarSmoothing"); fogOfWarSmoothingFrameSkip= config.getInt("FogOfWarSmoothingFrameSkip"); @@ -57,11 +59,23 @@ void World::end(){ for(int i= 0; igetGameSettings() != NULL) { + game->getGameSettings()->setFogOfWar(fogOfWar); + initCells(fogOfWar); //must be done after knowing faction number and dimensions + initMinimap(); + } +} + void World::init(Game *game, bool createUnits){ this->game = game; @@ -70,7 +84,9 @@ void World::init(Game *game, bool createUnits){ unitUpdater.init(game); GameSettings *gs = game->getGameSettings(); - fogOfWar = gs->getFogOfWar(); + if(fogOfWarOverride == false) { + fogOfWar = gs->getFogOfWar(); + } initFactionTypes(gs); initCells(fogOfWar); //must be done after knowing faction number and dimensions diff --git a/source/glest_game/world/world.h b/source/glest_game/world/world.h index 7a2e8b512..d5dfe7f36 100644 --- a/source/glest_game/world/world.h +++ b/source/glest_game/world/world.h @@ -1,7 +1,7 @@ // ============================================================== // This file is part of Glest (www.glest.org) // -// Copyright (C) 2001-2008 Martiņo Figueroa +// Copyright (C) 2001-2008 Martio Figueroa // // You can redistribute this code and/or modify it under // the terms of the GNU General Public License as published @@ -84,6 +84,7 @@ private: int nextUnitId; //config + bool fogOfWarOverride; bool fogOfWar; int fogOfWarSmoothingFrameSkip; bool fogOfWarSmoothing; @@ -149,6 +150,8 @@ public: Game * getGame() { return game; } + void setFogOfWar(bool value); + private: void initCells(bool fogOfWar); From ae2af01c2ea8e99635600f9b88b2276909927b14 Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Fri, 23 Apr 2010 02:53:57 +0000 Subject: [PATCH 4/7] Updated version # for new minor bugfix release --- mk/linux/configure.ac | 2 +- source/glest_game/facilities/game_util.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mk/linux/configure.ac b/mk/linux/configure.ac index 9a6e5e9e0..4a2ae6373 100644 --- a/mk/linux/configure.ac +++ b/mk/linux/configure.ac @@ -4,7 +4,7 @@ #---------------------------------------------------------------------------- AC_PREREQ([2.54]) -AC_INIT([megaglest], [3.3.4.1], [matze@braunis.de]) +AC_INIT([megaglest], [3.3.4.2], [matze@braunis.de]) AC_CONFIG_SRCDIR([mk/jam/build.jam]) AC_CONFIG_AUX_DIR([mk/autoconf]) diff --git a/source/glest_game/facilities/game_util.cpp b/source/glest_game/facilities/game_util.cpp index 7139f60b0..cb99ba6bf 100644 --- a/source/glest_game/facilities/game_util.cpp +++ b/source/glest_game/facilities/game_util.cpp @@ -25,7 +25,7 @@ using namespace Shared::Platform; namespace Glest{ namespace Game{ const string mailString= "contact_game@glest.org"; -const string glestVersionString= "v3.3.4.1"; +const string glestVersionString= "v3.3.4.2"; string getCrashDumpFileName(){ return "glest"+glestVersionString+".dmp"; From 2e702d8dd88d3a5764b1fb933a98414ba9b5cfd5 Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Fri, 23 Apr 2010 04:24:20 +0000 Subject: [PATCH 5/7] One final bugfix for 3.3.4.2 release, click mouse buttons > 2 on some mice would cause a crash --- source/shared_lib/sources/platform/sdl/window.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/source/shared_lib/sources/platform/sdl/window.cpp b/source/shared_lib/sources/platform/sdl/window.cpp index 438aea5d1..ee8f0cdf4 100644 --- a/source/shared_lib/sources/platform/sdl/window.cpp +++ b/source/shared_lib/sources/platform/sdl/window.cpp @@ -407,6 +407,7 @@ MouseButton Window::getMouseButton(int sdlButton) { default: //throw std::runtime_error("Mouse Button > 3 not handled."); SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s Line: %d] Mouse Button [%d] not handled.\n",__FILE__,__FUNCTION__,__LINE__,sdlButton); + return mbUnknown; } } From afcdc1209cdee54bbc866e78b5c7bd58c5401b90 Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Fri, 23 Apr 2010 14:08:19 +0000 Subject: [PATCH 6/7] Changed fow setting to use a property instead of lua method --- source/glest_game/game/script_manager.cpp | 12 ------------ source/glest_game/game/script_manager.h | 2 -- source/glest_game/menu/main_menu.h | 2 ++ source/glest_game/menu/menu_state_scenario.cpp | 10 +++++++++- 4 files changed, 11 insertions(+), 15 deletions(-) diff --git a/source/glest_game/game/script_manager.cpp b/source/glest_game/game/script_manager.cpp index d2bd87ac1..2673969b9 100644 --- a/source/glest_game/game/script_manager.cpp +++ b/source/glest_game/game/script_manager.cpp @@ -71,8 +71,6 @@ void ScriptManager::init(World* world, GameCamera *gameCamera){ luaScript.registerFunction(getLastDeadUnitId, "lastDeadUnit"); luaScript.registerFunction(getUnitCount, "unitCount"); luaScript.registerFunction(getUnitCountOfType, "unitCountOfType"); - luaScript.registerFunction(unfogMap, "unfogMap"); - //load code for(int i= 0; igetScriptCount(); ++i){ @@ -397,14 +395,4 @@ int ScriptManager::getUnitCountOfType(LuaHandle* luaHandle){ return luaArguments.getReturnCount(); } -void ScriptManager::unfogMap() { - world->setFogOfWar(false); -} - -int ScriptManager::unfogMap(LuaHandle* luaHandle){ - LuaArguments luaArguments(luaHandle); - thisScriptManager->unfogMap(); - return luaArguments.getReturnCount(); -} - }}//end namespace diff --git a/source/glest_game/game/script_manager.h b/source/glest_game/game/script_manager.h index dbb197650..421cc723b 100644 --- a/source/glest_game/game/script_manager.h +++ b/source/glest_game/game/script_manager.h @@ -136,7 +136,6 @@ private: void disableAi(int factionIndex); void setPlayerAsWinner(int factionIndex); void endGame(); - void unfogMap(); //wrappers, queries Vec2i getStartLocation(int factionIndex); @@ -163,7 +162,6 @@ private: static int disableAi(LuaHandle* luaHandle); static int setPlayerAsWinner(LuaHandle* luaHandle); static int endGame(LuaHandle* luaHandle); - static int unfogMap(LuaHandle* luaHandle); //callbacks, queries static int getStartLocation(LuaHandle* luaHandle); diff --git a/source/glest_game/menu/main_menu.h b/source/glest_game/menu/main_menu.h index dc426f7e3..c4926b021 100644 --- a/source/glest_game/menu/main_menu.h +++ b/source/glest_game/menu/main_menu.h @@ -46,6 +46,8 @@ struct ScenarioInfo bool defaultVictoryConditions; string desc; + + bool fogOfWar; }; class MenuState; diff --git a/source/glest_game/menu/menu_state_scenario.cpp b/source/glest_game/menu/menu_state_scenario.cpp index b897ca77d..e6bbc6ab4 100644 --- a/source/glest_game/menu/menu_state_scenario.cpp +++ b/source/glest_game/menu/menu_state_scenario.cpp @@ -1,7 +1,7 @@ // ============================================================== // This file is part of Glest (www.glest.org) // -// Copyright (C) 2001-2005 Martiņo Figueroa +// Copyright (C) 2001-2005 Martio Figueroa // // You can redistribute this code and/or modify it under // the terms of the GNU General Public License as published @@ -198,6 +198,13 @@ void MenuStateScenario::loadScenarioInfo(string file, ScenarioInfo *scenarioInfo scenarioInfo->desc+= lang.get("Map") + ": " + formatString(scenarioInfo->mapName) + "\n"; scenarioInfo->desc+= lang.get("Tileset") + ": " + formatString(scenarioInfo->tilesetName) + "\n"; scenarioInfo->desc+= lang.get("TechTree") + ": " + formatString(scenarioInfo->techTreeName) + "\n"; + + if(scenarioNode->hasChild("fog-of-war") == true) { + scenarioInfo->fogOfWar = scenarioNode->getChild("fog-of-war")->getAttribute("value")->getBoolValue(); + } + else { + scenarioInfo->fogOfWar = true; + } } void MenuStateScenario::loadGameSettings(const ScenarioInfo *scenarioInfo, GameSettings *gameSettings){ @@ -229,6 +236,7 @@ void MenuStateScenario::loadGameSettings(const ScenarioInfo *scenarioInfo, GameS } gameSettings->setFactionCount(factionCount); + gameSettings->setFogOfWar(scenarioInfo->fogOfWar); } ControlType MenuStateScenario::strToControllerType(const string &str){ From a0fbe84054a645766d16185f5630355106ba2a75 Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Fri, 23 Apr 2010 14:14:47 +0000 Subject: [PATCH 7/7] Updated version # for last minor release of 3.3.4 --- mk/linux/configure.ac | 2 +- source/glest_game/facilities/game_util.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mk/linux/configure.ac b/mk/linux/configure.ac index 4a2ae6373..a85153e66 100644 --- a/mk/linux/configure.ac +++ b/mk/linux/configure.ac @@ -4,7 +4,7 @@ #---------------------------------------------------------------------------- AC_PREREQ([2.54]) -AC_INIT([megaglest], [3.3.4.2], [matze@braunis.de]) +AC_INIT([megaglest], [3.3.4.3], [matze@braunis.de]) AC_CONFIG_SRCDIR([mk/jam/build.jam]) AC_CONFIG_AUX_DIR([mk/autoconf]) diff --git a/source/glest_game/facilities/game_util.cpp b/source/glest_game/facilities/game_util.cpp index cb99ba6bf..f391c17bd 100644 --- a/source/glest_game/facilities/game_util.cpp +++ b/source/glest_game/facilities/game_util.cpp @@ -25,7 +25,7 @@ using namespace Shared::Platform; namespace Glest{ namespace Game{ const string mailString= "contact_game@glest.org"; -const string glestVersionString= "v3.3.4.2"; +const string glestVersionString= "v3.3.4.3"; string getCrashDumpFileName(){ return "glest"+glestVersionString+".dmp";