From 1e6f5283eceff138873ec54159ad8f716ed39b45 Mon Sep 17 00:00:00 2001 From: Bjørn Lindeijer Date: Sat, 23 Dec 2006 18:01:01 +0000 Subject: Load the databases at the start of the LOGIN state, after the updates are loaded. --- src/main.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index f54b0792..1a171d84 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -286,11 +286,6 @@ void init_engine(const Options &options) errorMessage = err; logger->log("Warning: %s", err); } - - // Load XML databases - EquipmentDB::load(); - ItemDB::load(); - MonsterDB::load(); } /** Clear the engine */ @@ -625,6 +620,12 @@ int main(int argc, char *argv[]) switch (state) { case LOGIN_STATE: logger->log("State: LOGIN"); + + // Load XML databases + EquipmentDB::load(); + ItemDB::load(); + MonsterDB::load(); + if (!loginData.password.empty()) { state = ACCOUNT_STATE; } else { -- cgit v1.2.3-60-g2f50