summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorBertram <bertram@cegetel.net>2009-10-22 02:31:21 +0200
committerBertram <bertram@cegetel.net>2009-10-22 02:31:21 +0200
commit3c6d873fe5584c41a0038758e52ecca843c1e182 (patch)
tree198cef1684e7a198c4017dbd8732629fb1270bca /src/main.cpp
parent4720134d58cd5fe0846ed911b360ed75641cb874 (diff)
downloadmana-3c6d873fe5584c41a0038758e52ecca843c1e182.tar.gz
mana-3c6d873fe5584c41a0038758e52ecca843c1e182.tar.bz2
mana-3c6d873fe5584c41a0038758e52ecca843c1e182.tar.xz
mana-3c6d873fe5584c41a0038758e52ecca843c1e182.zip
Optimized game startup sequence for eAthena in order to cope a bit better with network errors.
Unfortunately, it isn't enough: The bug seems to be elsewhere...
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 761f825d..92cbae77 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1092,6 +1092,14 @@ int main(int argc, char *argv[])
case STATE_CONNECT_GAME:
logger->log("State: CONNECT GAME");
+
+ // Allow any alpha opacity
+ SkinLoader::instance()->setMinimumOpacity(-1.0f);
+
+ // Fade out logon-music here too to give the desired effect
+ // of "flowing" into the game.
+ sound.fadeOutMusic(1000);
+
Net::getGameHandler()->connect();
currentDialog = new ConnectionDialog(STATE_SWITCH_CHARACTER);
break;
@@ -1103,11 +1111,6 @@ int main(int argc, char *argv[])
Net::getGameHandler()->inGame();
- // Allow any alpha opacity
- SkinLoader::instance()->setMinimumOpacity(-1.0f);
-
- sound.fadeOutMusic(1000);
-
delete setupButton;
delete desktop;
setupButton = NULL;