63 for (DisableMap::iterator itr = m_DisableMap.begin(); itr != m_DisableMap.end(); ++itr)
74 TC_LOG_INFO(
"server.loading",
">> Loaded 0 disables. DB table `disables` is empty!");
81 fields = result->Fetch();
83 if (type >= MAX_DISABLE_TYPES)
85 TC_LOG_ERROR(
"sql.sql",
"Invalid type %u specified in `disables` table, skipped.", type);
91 std::string params_0 = fields[3].
GetString();
92 std::string params_1 = fields[4].
GetString();
102 TC_LOG_ERROR(
"sql.sql",
"Spell entry %u from `disables` doesn't exist in dbc, skipped.", entry);
108 TC_LOG_ERROR(
"sql.sql",
"Disable flags for spell %u are invalid, skipped.", entry);
115 for (
uint8 i = 0; i < tokens.size(); )
116 data.params[0].insert(atoi(tokens[i++]));
122 for (
uint8 i = 0; i < tokens.size(); )
123 data.params[1].insert(atoi(tokens[i++]));
135 TC_LOG_ERROR(
"sql.sql",
"Map entry %u from `disables` doesn't exist in dbc, skipped.", entry);
138 bool isFlagInvalid =
false;
143 isFlagInvalid =
true;
154 isFlagInvalid =
true;
158 TC_LOG_ERROR(
"sql.sql",
"Battleground map %u specified to be disabled in map case, skipped.", entry);
163 TC_LOG_ERROR(
"sql.sql",
"Disable flags for map %u are invalid, skipped.", entry);
171 TC_LOG_ERROR(
"sql.sql",
"Battleground entry %u from `disables` doesn't exist in dbc, skipped.", entry);
175 TC_LOG_ERROR(
"sql.sql",
"Disable flags specified for battleground %u, useless data.", entry);
180 TC_LOG_ERROR(
"sql.sql",
"OutdoorPvPTypes value %u from `disables` is invalid, skipped.", entry);
184 TC_LOG_ERROR(
"sql.sql",
"Disable flags specified for outdoor PvP %u, useless data.", entry);
189 TC_LOG_ERROR(
"sql.sql",
"Achievement Criteria entry %u from `disables` doesn't exist in dbc, skipped.", entry);
193 TC_LOG_ERROR(
"sql.sql",
"Disable flags specified for Achievement Criteria %u, useless data.", entry);
200 TC_LOG_ERROR(
"sql.sql",
"Map entry %u from `disables` doesn't exist in dbc, skipped.", entry);
229 TC_LOG_ERROR(
"sql.sql",
"Map entry %u from `disables` doesn't exist in dbc, skipped.", entry);
240 m_DisableMap[type].insert(DisableTypeMap::value_type(entry, data));
243 while (result->NextRow());
char const * MapTypeNames[]
Definition: DisableMgr.cpp:30
Definition: DBCEnums.h:406
Definition: VMapManager2.h:73
MapDifficultyEntry const * GetMapDifficultyData(uint32 mapId, Difficulty difficulty)
Definition: DBCStores.cpp:724
Class used to access individual fields of database query result.
Definition: Field.h:56
DBCStorage< BattlemasterListEntry > sBattlemasterListStore(BattlemasterListfmt)
Definition: VMapManager2.h:75
Definition: DBCEnums.h:482
DisableType
Definition: DisableMgr.h:27
uint32 getMSTime()
Definition: Timer.h:24
Definition: DBCStructure.h:830
WorldDatabaseWorkerPool WorldDatabase
Accessor to the world database.
Definition: DatabaseEnv.cpp:20
Definition: DBCEnums.h:480
Definition: SharedDefines.h:4813
uint8 GetUInt8() const
Definition: Field.h:70
Definition: DisableMgr.h:45
uint32 InstanceType
Definition: DBCStructure.h:834
Definition: DBCEnums.h:481
Definition: DisableMgr.h:46
Definition: DisableMgr.h:36
#define MAX_OUTDOORPVP_TYPES
Definition: OutdoorPvP.h:37
Definition: SharedDefines.h:4808
#define sSpellMgr
Definition: SpellMgr.h:756
Definition: DisableMgr.h:32
uint32_t uint32
Definition: Define.h:150
Definition: DisableMgr.h:35
std::shared_ptr< ResultSet > QueryResult
Definition: QueryResult.h:61
Definition: DBCEnums.h:409
Definition: DisableMgr.h:29
Definition: DBCEnums.h:410
Definition: DisableMgr.h:30
Definition: DisableMgr.h:33
uint32 GetMSTimeDiffToNow(uint32 oldMSTime)
Definition: Timer.h:42
QueryResult Query(const char *sql, T *connection=nullptr)
Definition: DatabaseWorkerPool.cpp:113
Definition: DBCEnums.h:478
DBCStorage< MapEntry > sMapStore(Mapfmt)
Definition: DisableMgr.h:31
Definition: SharedDefines.h:4812
uint32 GetUInt32() const
Definition: Field.h:146
uint8_t uint8
Definition: Define.h:152
Definition: VMapManager2.h:74
#define TC_LOG_INFO(filterType__,...)
Definition: Log.h:201
#define TC_LOG_ERROR(filterType__,...)
Definition: Log.h:207
Definition: DisableMgr.h:34
uint8 flags
Definition: DisableMgr.cpp:44
Definition: DBCEnums.h:483
Definition: DisableMgr.h:48
Definition: DisableMgr.h:44
std::string GetString() const
Definition: Field.h:276
Definition: DBCEnums.h:479
Definition: VMapManager2.h:72
#define sAchievementMgr
Definition: AchievementMgr.h:501