* Remove useless CheckDB functionality. This does not belong in core in any shape or form.

--HG--
branch : trunk
This commit is contained in:
XTZGZoReX
2009-12-29 18:25:21 +01:00
parent 5b975766f5
commit 2159602f27
7 changed files with 0 additions and 54 deletions
-25
View File
@@ -9014,28 +9014,3 @@ void ObjectMgr::LoadCreatureClassLevelStats()
sLog.outString();
sLog.outString( ">> Loaded %u creature base stats.", counter);
}
bool ObjectMgr::CheckDB() const
{
CreatureInfo const* cInfo = sCreatureStorage.LookupEntry<CreatureInfo>(28511);
if(!cInfo || cInfo->spells[4] != 51890)
return false;
cInfo = sCreatureStorage.LookupEntry<CreatureInfo>(30068);
if(!cInfo || cInfo->faction_A != 21)
return false;
cInfo = sCreatureStorage.LookupEntry<CreatureInfo>(28768); // Dark Rider of Acherus
if(!cInfo || !cInfo->ScriptID)
return false;
cInfo = sCreatureStorage.LookupEntry<CreatureInfo>(32627); // Wintergrasp Siege Engine
if(!cInfo || !cInfo->spells[0] || cInfo->VehicleId != 117)
return false;
cInfo = sCreatureStorage.LookupEntry<CreatureInfo>(33114); // Flame Leviathan Seat
if(!cInfo || cInfo->VehicleId != 341)
return false;
return true;
}
-2
View File
@@ -934,8 +934,6 @@ class ObjectMgr
GmTicketList m_GMTicketList;
uint64 GenerateGMTicketId();
bool CheckDB() const;
// for wintergrasp only
GraveYardMap mGraveYardMap;
protected:
-9
View File
@@ -3982,12 +3982,3 @@ void SpellMgr::LoadSpellLinked()
sLog.outString();
sLog.outString( ">> Loaded %u linked spells", count );
}
bool SpellMgr::CheckDB() const
{
SpellScriptTargetBounds bounds = spellmgr.GetSpellScriptTargetBounds(30531);
if(bounds.first == bounds.second || bounds.first->second.targetEntry != 17256)
return false;
return true;
}
-2
View File
@@ -1202,8 +1202,6 @@ class SpellMgr
void LoadPetDefaultSpells();
void LoadSpellAreas();
bool CheckDB() const;
private:
bool _isPositiveSpell(uint32 spellId, bool deep) const;
bool _isPositiveEffect(uint32 spellId, uint32 effIndex, bool deep) const;
-14
View File
@@ -1203,7 +1203,6 @@ void World::LoadConfigSettings(bool reload)
m_configs[CONFIG_SHOW_KICK_IN_WORLD] = sConfig.GetBoolDefault("ShowKickInWorld", false);
m_configs[CONFIG_INTERVAL_LOG_UPDATE] = sConfig.GetIntDefault("RecordUpdateTimeDiffInterval", 60000);
m_configs[CONFIG_MIN_LOG_UPDATE] = sConfig.GetIntDefault("MinRecordUpdateTimeDiff", 10);
m_configs[CONFIG_CHECK_DB] = sConfig.GetBoolDefault("CheckDB", true);
m_configs[CONFIG_NUMTHREADS] = sConfig.GetIntDefault("MapUpdate.Threads", 1);
std::string forbiddenmaps = sConfig.GetStringDefault("ForbiddenMaps", "");
@@ -1612,19 +1611,6 @@ void World::SetInitialWorldSettings()
if (!LoadScriptingModule())
exit(1);
/// Check db
if (m_configs[CONFIG_CHECK_DB])
{
sLog.outString("Checking DB...");
if (!objmgr.CheckDB() || !spellmgr.CheckDB())
{
sLog.outError("Your world DB is outdated. Please reapply sqls in sql\\FULL folder, or disable CheckDB option in config file (not recommended).");
exit(1);
}
}
else
sLog.outError("You have disabled DB check. We strongly recommend you to enable it to prevent unpredictable bugs and crashes.");
///- Initialize game time and timers
sLog.outDebug("DEBUG:: Initialize game time and timers");
m_gameTime = time(NULL);
-1
View File
@@ -263,7 +263,6 @@ enum WorldConfigs
CONFIG_SHOW_KICK_IN_WORLD,
CONFIG_INTERVAL_LOG_UPDATE,
CONFIG_MIN_LOG_UPDATE,
CONFIG_CHECK_DB,
CONFIG_ENABLE_SINFO_LOGIN,
CONFIG_PLAYER_ALLOW_COMMANDS,
CONFIG_PET_LOS,
-1
View File
@@ -2017,4 +2017,3 @@ ShowKickInWorld = 0
RecordUpdateTimeDiffInterval = 60000
MinRecordUpdateTimeDiff = 10
PlayerStart.String = ""
CheckDB = 1