diff options
author | Andrei Karas <akaras@inbox.ru> | 2016-05-12 14:58:53 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2016-05-12 14:58:53 +0300 |
commit | 81123fd6cc5226c3332f3d3a31df152be7121579 (patch) | |
tree | 6fad0b291bad3afb871d54199e195c5fdb6be915 | |
parent | c65f64290f550db0762a14bf131395df62ab7a43 (diff) | |
download | manaplus-81123fd6cc5226c3332f3d3a31df152be7121579.tar.gz manaplus-81123fd6cc5226c3332f3d3a31df152be7121579.tar.bz2 manaplus-81123fd6cc5226c3332f3d3a31df152be7121579.tar.xz manaplus-81123fd6cc5226c3332f3d3a31df152be7121579.zip |
Dont load unsupported dbs in legacy servers.
-rw-r--r-- | src/client.cpp | 30 |
1 files changed, 22 insertions, 8 deletions
diff --git a/src/client.cpp b/src/client.cpp index 3ed950101..a18f7c3a6 100644 --- a/src/client.cpp +++ b/src/client.cpp @@ -580,13 +580,20 @@ void Client::gameClear() ColorDB::unload(); SoundDB::unload(); EmoteDB::unload(); - HorseDB::unload(); ItemDB::unload(); - MercenaryDB::unload(); - HomunculusDB::unload(); +#ifdef EATHENA_SUPPORT + const ServerTypeT type = Net::getNetworkType(); + if (type == ServerType::EATHENA || + type == ServerType::EVOL2) + { + MercenaryDB::unload(); + HomunculusDB::unload(); + SkillUnitDb::unload(); + HorseDB::unload(); + } +#endif MonsterDB::unload(); NPCDB::unload(); - SkillUnitDb::unload(); NpcDialogDB::unload(); AvatarDB::unload(); BadgesDB::unload(); @@ -1300,17 +1307,24 @@ int Client::gameExec() MapDB::load(); ItemDB::load(); Being::load(); - MercenaryDB::load(); - HomunculusDB::load(); +#ifdef EATHENA_SUPPORT + const ServerTypeT type = Net::getNetworkType(); + if (type == ServerType::EATHENA || + type == ServerType::EVOL2) + { + MercenaryDB::load(); + HomunculusDB::load(); + SkillUnitDb::load(); + HorseDB::load(); + } +#endif MonsterDB::load(); AvatarDB::load(); BadgesDB::load(); WeaponsDB::load(); NPCDB::load(); - SkillUnitDb::load(); NpcDialogDB::load(); PETDB::load(); - HorseDB::load(); EmoteDB::load(); // ModDB::load(); StatusEffectDB::load(); |