mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-04 03:23:48 +00:00
Refactor(Core/Misc): Remove remaining COMPILER_HAS_CPP11_SUPPORT related macros (#1627)
* Delete macros UNORDERED_MAP * Delete macros UNORDERED_SET
This commit is contained in:
@@ -165,7 +165,7 @@ typedef std::vector<uint32> CreatureQuestItemList;
|
||||
typedef std::unordered_map<uint32, CreatureQuestItemList> CreatureQuestItemMap;
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint32, CreatureTemplate> CreatureTemplateContainer;
|
||||
typedef std::unordered_map<uint32, CreatureTemplate> CreatureTemplateContainer;
|
||||
|
||||
// GCC have alternative #pragma pack(N) syntax and old gcc version not support pack(push, N), also any gcc version not support it at some platform
|
||||
#if defined(__GNUC__)
|
||||
@@ -213,7 +213,7 @@ struct CreatureBaseStats
|
||||
static CreatureBaseStats const* GetBaseStats(uint8 level, uint8 unitClass);
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint16, CreatureBaseStats> CreatureBaseStatsContainer;
|
||||
typedef std::unordered_map<uint16, CreatureBaseStats> CreatureBaseStatsContainer;
|
||||
|
||||
struct CreatureLocale
|
||||
{
|
||||
@@ -240,8 +240,8 @@ struct EquipmentInfo
|
||||
};
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint8, EquipmentInfo> EquipmentInfoContainerInternal;
|
||||
typedef UNORDERED_MAP<uint32, EquipmentInfoContainerInternal> EquipmentInfoContainer;
|
||||
typedef std::unordered_map<uint8, EquipmentInfo> EquipmentInfoContainerInternal;
|
||||
typedef std::unordered_map<uint32, EquipmentInfoContainerInternal> EquipmentInfoContainer;
|
||||
|
||||
// from `creature` table
|
||||
struct CreatureData
|
||||
@@ -282,7 +282,7 @@ struct CreatureModelInfo
|
||||
};
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint16, CreatureModelInfo> CreatureModelContainer;
|
||||
typedef std::unordered_map<uint16, CreatureModelInfo> CreatureModelContainer;
|
||||
|
||||
enum InhabitTypeValues
|
||||
{
|
||||
@@ -323,7 +323,7 @@ struct CreatureAddon
|
||||
std::vector<uint32> auras;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, CreatureAddon> CreatureAddonContainer;
|
||||
typedef std::unordered_map<uint32, CreatureAddon> CreatureAddonContainer;
|
||||
|
||||
// Vendors
|
||||
struct VendorItem
|
||||
@@ -399,7 +399,7 @@ struct TrainerSpell
|
||||
bool IsCastable() const { return learnedSpell[0] != spell; }
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32 /*spellid*/, TrainerSpell> TrainerSpellMap;
|
||||
typedef std::unordered_map<uint32 /*spellid*/, TrainerSpell> TrainerSpellMap;
|
||||
|
||||
struct TrainerSpellData
|
||||
{
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#define _FORMATIONS_H
|
||||
|
||||
#include "Define.h"
|
||||
#include "UnorderedMap.h"
|
||||
#include <unordered_map>
|
||||
#include <map>
|
||||
|
||||
class Creature;
|
||||
@@ -24,7 +24,7 @@ struct FormationInfo
|
||||
uint16 point_2;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32/*memberDBGUID*/, FormationInfo*> CreatureGroupInfoType;
|
||||
typedef std::unordered_map<uint32/*memberDBGUID*/, FormationInfo*> CreatureGroupInfoType;
|
||||
|
||||
class FormationMgr
|
||||
{
|
||||
|
||||
@@ -541,8 +541,8 @@ struct GameObjectTemplateAddon
|
||||
};
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint32, GameObjectTemplate> GameObjectTemplateContainer;
|
||||
typedef UNORDERED_MAP<uint32, GameObjectTemplateAddon> GameObjectTemplateAddonContainer;
|
||||
typedef std::unordered_map<uint32, GameObjectTemplate> GameObjectTemplateContainer;
|
||||
typedef std::unordered_map<uint32, GameObjectTemplateAddon> GameObjectTemplateAddonContainer;
|
||||
|
||||
class OPvPCapturePoint;
|
||||
struct TransportAnimation;
|
||||
@@ -586,7 +586,7 @@ struct GameObjectAddon
|
||||
uint32 InvisibilityValue;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, GameObjectAddon> GameObjectAddonContainer;
|
||||
typedef std::unordered_map<uint32, GameObjectAddon> GameObjectAddonContainer;
|
||||
|
||||
// client side GO show states
|
||||
enum GOState
|
||||
|
||||
@@ -28,7 +28,7 @@ struct EnchStoreItem
|
||||
};
|
||||
|
||||
typedef std::vector<EnchStoreItem> EnchStoreList;
|
||||
typedef UNORDERED_MAP<uint32, EnchStoreList> EnchantmentStore;
|
||||
typedef std::unordered_map<uint32, EnchStoreList> EnchantmentStore;
|
||||
|
||||
static EnchantmentStore RandomItemEnch;
|
||||
|
||||
|
||||
@@ -778,7 +778,7 @@ struct ItemTemplate
|
||||
};
|
||||
|
||||
// Benchmarked: Faster than std::map (insert/find)
|
||||
typedef UNORDERED_MAP<uint32, ItemTemplate> ItemTemplateContainer;
|
||||
typedef std::unordered_map<uint32, ItemTemplate> ItemTemplateContainer;
|
||||
|
||||
struct ItemLocale
|
||||
{
|
||||
|
||||
@@ -117,8 +117,8 @@ class Transport;
|
||||
class StaticTransport;
|
||||
class MotionTransport;
|
||||
|
||||
typedef UNORDERED_MAP<Player*, UpdateData> UpdateDataMapType;
|
||||
typedef UNORDERED_SET<uint32> UpdatePlayerSet;
|
||||
typedef std::unordered_map<Player*, UpdateData> UpdateDataMapType;
|
||||
typedef std::unordered_set<uint32> UpdatePlayerSet;
|
||||
|
||||
class Object
|
||||
{
|
||||
|
||||
@@ -36,7 +36,7 @@ class AsynchPetSummon
|
||||
uint64 m_casterGUID;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, PetSpell> PetSpellMap;
|
||||
typedef std::unordered_map<uint32, PetSpell> PetSpellMap;
|
||||
typedef std::vector<uint32> AutoSpellList;
|
||||
|
||||
class Player;
|
||||
|
||||
@@ -118,8 +118,8 @@ struct SpellModifier
|
||||
Aura* const ownerAura;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, PlayerTalent*> PlayerTalentMap;
|
||||
typedef UNORDERED_MAP<uint32, PlayerSpell*> PlayerSpellMap;
|
||||
typedef std::unordered_map<uint32, PlayerTalent*> PlayerTalentMap;
|
||||
typedef std::unordered_map<uint32, PlayerSpell*> PlayerSpellMap;
|
||||
typedef std::list<SpellModifier*> SpellModList;
|
||||
|
||||
typedef std::list<uint64> WhisperListContainer;
|
||||
@@ -134,7 +134,7 @@ struct SpellCooldown
|
||||
};
|
||||
|
||||
typedef std::map<uint32, SpellCooldown> SpellCooldowns;
|
||||
typedef UNORDERED_MAP<uint32 /*instanceId*/, time_t/*releaseTime*/> InstanceTimeMap;
|
||||
typedef std::unordered_map<uint32 /*instanceId*/, time_t/*releaseTime*/> InstanceTimeMap;
|
||||
|
||||
enum TrainerSpellState
|
||||
{
|
||||
@@ -517,7 +517,7 @@ enum AtLoginFlags
|
||||
};
|
||||
|
||||
typedef std::map<uint32, QuestStatusData> QuestStatusMap;
|
||||
typedef UNORDERED_SET<uint32> RewardedQuestSet;
|
||||
typedef std::unordered_set<uint32> RewardedQuestSet;
|
||||
|
||||
// quest, keep
|
||||
typedef std::map<uint32, bool> QuestStatusSaveMap;
|
||||
@@ -556,7 +556,7 @@ struct SkillStatusData
|
||||
SkillUpdateState uState;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, SkillStatusData> SkillStatusMap;
|
||||
typedef std::unordered_map<uint32, SkillStatusData> SkillStatusMap;
|
||||
|
||||
class Quest;
|
||||
class Spell;
|
||||
@@ -1637,7 +1637,7 @@ class Player : public Unit, public GridObject<Player>
|
||||
uint8 unReadMails;
|
||||
time_t m_nextMailDelivereTime;
|
||||
|
||||
typedef UNORDERED_MAP<uint32, Item*> ItemMap;
|
||||
typedef std::unordered_map<uint32, Item*> ItemMap;
|
||||
|
||||
ItemMap mMitems; //template defined in objectmgr.cpp
|
||||
|
||||
@@ -2364,7 +2364,7 @@ class Player : public Unit, public GridObject<Player>
|
||||
void SetEntryPoint();
|
||||
|
||||
// currently visible objects at player client
|
||||
typedef UNORDERED_SET<uint64> ClientGUIDs;
|
||||
typedef std::unordered_set<uint64> ClientGUIDs;
|
||||
ClientGUIDs m_clientGUIDs;
|
||||
std::vector<Unit*> m_newVisible; // pussywizard
|
||||
|
||||
@@ -2656,7 +2656,7 @@ class Player : public Unit, public GridObject<Player>
|
||||
//We allow only one timed quest active at the same time. Below can then be simple value instead of set.
|
||||
typedef std::set<uint32> QuestSet;
|
||||
typedef std::set<uint32> SeasonalQuestSet;
|
||||
typedef UNORDERED_MAP<uint32,SeasonalQuestSet> SeasonalEventQuestMap;
|
||||
typedef std::unordered_map<uint32,SeasonalQuestSet> SeasonalEventQuestMap;
|
||||
QuestSet m_timedquests;
|
||||
QuestSet m_weeklyquests;
|
||||
QuestSet m_monthlyquests;
|
||||
|
||||
@@ -19462,7 +19462,7 @@ void Unit::BuildCooldownPacket(WorldPacket& data, uint8 flags, PacketCooldowns c
|
||||
data.Initialize(SMSG_SPELL_COOLDOWN, 8 + 1 + (4 + 4) * cooldowns.size());
|
||||
data << uint64(GetGUID());
|
||||
data << uint8(flags);
|
||||
for (UNORDERED_MAP<uint32, uint32>::const_iterator itr = cooldowns.begin(); itr != cooldowns.end(); ++itr)
|
||||
for (std::unordered_map<uint32, uint32>::const_iterator itr = cooldowns.begin(); itr != cooldowns.end(); ++itr)
|
||||
{
|
||||
data << uint32(itr->first);
|
||||
data << uint32(itr->second);
|
||||
|
||||
@@ -1070,7 +1070,7 @@ struct GlobalCooldown
|
||||
uint32 cast_time;
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32 /*category*/, GlobalCooldown> GlobalCooldownList;
|
||||
typedef std::unordered_map<uint32 /*category*/, GlobalCooldown> GlobalCooldownList;
|
||||
|
||||
class GlobalCooldownMgr // Shared by Player and CharmInfo
|
||||
{
|
||||
@@ -1289,7 +1289,7 @@ enum SpellCooldownFlags
|
||||
SPELL_COOLDOWN_FLAG_INCLUDE_EVENT_COOLDOWNS = 0x2 ///< Starts GCD for spells that should start their cooldown on events, requires SPELL_COOLDOWN_FLAG_INCLUDE_GCD set
|
||||
};
|
||||
|
||||
typedef UNORDERED_MAP<uint32, uint32> PacketCooldowns;
|
||||
typedef std::unordered_map<uint32, uint32> PacketCooldowns;
|
||||
|
||||
// delay time next attack to prevent client attack animation problems
|
||||
#define ATTACK_DISPLAY_DELAY 200
|
||||
@@ -1343,7 +1343,7 @@ private:
|
||||
class Unit : public WorldObject
|
||||
{
|
||||
public:
|
||||
typedef UNORDERED_SET<Unit*> AttackerSet;
|
||||
typedef std::unordered_set<Unit*> AttackerSet;
|
||||
typedef std::set<Unit*> ControlSet;
|
||||
|
||||
typedef std::multimap<uint32, Aura*> AuraMap;
|
||||
@@ -1361,7 +1361,7 @@ class Unit : public WorldObject
|
||||
typedef std::list<Aura*> AuraList;
|
||||
typedef std::list<AuraApplication *> AuraApplicationList;
|
||||
typedef std::list<DiminishingReturn> Diminishing;
|
||||
typedef UNORDERED_SET<uint32> ComboPointHolderSet;
|
||||
typedef std::unordered_set<uint32> ComboPointHolderSet;
|
||||
|
||||
typedef std::map<uint8, AuraApplication*> VisibleAuraMap;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user