summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorPhilipp Sehmisch <tmw@crushnet.org>2007-02-20 23:45:51 +0000
committerPhilipp Sehmisch <tmw@crushnet.org>2007-02-20 23:45:51 +0000
commit7cb624d0e6a2844360f28fdb8390f866aa3393c7 (patch)
tree1444fa899a8266072472cc1045ffb503bcab5ee1 /src/main.cpp
parent6f4c416887d2a006a13dbd4e54932d46b59b0b17 (diff)
downloadmana-7cb624d0e6a2844360f28fdb8390f866aa3393c7.tar.gz
mana-7cb624d0e6a2844360f28fdb8390f866aa3393c7.tar.bz2
mana-7cb624d0e6a2844360f28fdb8390f866aa3393c7.tar.xz
mana-7cb624d0e6a2844360f28fdb8390f866aa3393c7.zip
Added support for customdata directory.
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp18
1 files changed, 15 insertions, 3 deletions
diff --git a/src/main.cpp b/src/main.cpp
index a9bcd077..383e7f39 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -535,7 +535,7 @@ int main(int argc, char *argv[])
SDL_Event event;
if (options.skipUpdate && state != ERROR_STATE) {
- state = LOGIN_STATE;
+ state = LOADDATA_STATE;
}
else {
state = UPDATE_STATE;
@@ -623,6 +623,7 @@ int main(int argc, char *argv[])
break;
// Those states don't cause a network disconnect
+ case LOADDATA_STATE:
case ACCOUNT_STATE:
case CHAR_CONNECT_STATE:
case CONNECTING_STATE:
@@ -643,13 +644,24 @@ int main(int argc, char *argv[])
}
switch (state) {
- case LOGIN_STATE:
- logger->log("State: LOGIN");
+ case LOADDATA_STATE:
+ logger->log("State: LOADDATA");
+
+ //add customdata directory
+ ResourceManager::getInstance()->searchAndAddArchives(
+ "customdata/",
+ "zip",
+ false);
// Load XML databases
EquipmentDB::load();
ItemDB::load();
MonsterDB::load();
+ state = LOGIN_STATE;
+ break;
+
+ case LOGIN_STATE:
+ logger->log("State: LOGIN");
if (!loginData.password.empty()) {
state = ACCOUNT_STATE;