mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 13:37:00 +00:00
[9849] Implement character database clean up.
This can be disabled by config option. Flag for clean up can be set for example on client version change. Signed-off-by: hunuza <hunuza@gmail.com>
This commit is contained in:
parent
2c6d48b912
commit
d1130af777
14 changed files with 228 additions and 4 deletions
|
|
@ -60,6 +60,7 @@
|
|||
#include "WaypointManager.h"
|
||||
#include "GMTicketMgr.h"
|
||||
#include "Util.h"
|
||||
#include "CharacterDatabaseCleaner.h"
|
||||
|
||||
INSTANTIATE_SINGLETON_1( World );
|
||||
|
||||
|
|
@ -516,6 +517,7 @@ void World::LoadConfigSettings(bool reload)
|
|||
///- Read other configuration items from the config file
|
||||
setConfigMinMax(CONFIG_UINT32_COMPRESSION, "Compression", 1, 1, 9);
|
||||
setConfig(CONFIG_BOOL_ADDON_CHANNEL, "AddonChannel", true);
|
||||
setConfig(CONFIG_BOOL_CLEAN_CHARACTER_DB, "CleanCharacterDB", true);
|
||||
setConfig(CONFIG_BOOL_GRID_UNLOAD, "GridUnload", true);
|
||||
setConfigPos(CONFIG_UINT32_INTERVAL_SAVE, "PlayerSave.Interval", 15 * MINUTE * IN_MILLISECONDS);
|
||||
setConfigMinMax(CONFIG_UINT32_MIN_LEVEL_STAT_SAVE, "PlayerSave.Stats.MinLevel", 0, 0, MAX_LEVEL);
|
||||
|
|
@ -1093,6 +1095,8 @@ void World::SetInitialWorldSettings()
|
|||
sLog.outString( "Loading Pet Name Parts..." );
|
||||
sObjectMgr.LoadPetNames();
|
||||
|
||||
CharacterDatabaseCleaner::CleanDatabase();
|
||||
|
||||
sLog.outString( "Loading the max pet number..." );
|
||||
sObjectMgr.LoadPetNumber();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue