18#ifndef TRINITY_CONDITIONMGR_H
19#define TRINITY_CONDITIONMGR_H
25#include <unordered_map>
26#include <unordered_set>
207 mConditionTargets[0] = target0;
208 mConditionTargets[1] = target1;
209 mConditionTargets[2] = target2;
210 mLastFailedCondition =
nullptr;
249 NegativeCondition =
false;
253 uint32 GetSearcherTypeMaskForCondition()
const;
255 uint32 GetMaxAvailableConditionTargets()
const;
257 std::string ToString(
bool ext =
false)
const;
276 void LoadConditions(
bool isReload =
false);
277 bool isConditionTypeValid(
Condition* cond)
const;
290 bool IsObjectMeetingVehicleSpellConditions(
uint32 creatureId,
uint32 spellId,
Player* player,
Unit* vehicle)
const;
294 bool IsSpellUsedInSpellClickConditions(
uint32 spellId)
const;
308 bool isSourceTypeValid(
Condition* cond)
const;
310 bool addToGossipMenus(
Condition* cond)
const;
311 bool addToGossipMenuItems(
Condition* cond)
const;
312 bool addToSpellImplicitTargetConditions(
Condition* cond)
const;
316 static void LogUselessConditionValue(
Condition const* cond,
uint8 index, std::string_view value);
331#define sConditionMgr ConditionMgr::instance()
std::unordered_map< uint32, ConditionContainer > ConditionsByEntryMap
std::unordered_map< uint32, ConditionContainer > ConditionReferenceContainer
std::unordered_map< std::pair< int32, uint32 >, ConditionsByEntryMap > SmartEventConditionContainer
@ CONDITION_SOURCE_TYPE_MAX
@ CONDITION_SOURCE_TYPE_CONVERSATION_LINE
@ CONDITION_SOURCE_TYPE_VEHICLE_SPELL
@ CONDITION_SOURCE_TYPE_DISENCHANT_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_REFERENCE_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_TERRAIN_SWAP
@ CONDITION_SOURCE_TYPE_NPC_VENDOR
@ CONDITION_SOURCE_TYPE_GOSSIP_MENU_OPTION
@ CONDITION_SOURCE_TYPE_SPELL_CLICK_EVENT
@ CONDITION_SOURCE_TYPE_MAIL_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_PHASE
@ CONDITION_SOURCE_TYPE_SPELL_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_SMART_EVENT
@ CONDITION_SOURCE_TYPE_PICKPOCKETING_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_PROSPECTING_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_AREATRIGGER_CLIENT_TRIGGERED
@ CONDITION_SOURCE_TYPE_AREATRIGGER
@ CONDITION_SOURCE_TYPE_SPAWN_GROUP
@ CONDITION_SOURCE_TYPE_SPELL
@ CONDITION_SOURCE_TYPE_FISHING_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_OBJECT_ID_VISIBILITY
@ CONDITION_SOURCE_TYPE_GOSSIP_MENU
@ CONDITION_SOURCE_TYPE_CREATURE_TEMPLATE_VEHICLE
@ CONDITION_SOURCE_TYPE_ITEM_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_SPELL_IMPLICIT_TARGET
@ CONDITION_SOURCE_TYPE_GRAVEYARD
@ CONDITION_SOURCE_TYPE_SKINNING_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_TRAINER_SPELL
@ CONDITION_SOURCE_TYPE_CREATURE_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_GAMEOBJECT_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_MILLING_LOOT_TEMPLATE
@ CONDITION_SOURCE_TYPE_SPELL_PROC
@ CONDITION_SOURCE_TYPE_QUEST_AVAILABLE
@ CONDITION_SOURCE_TYPE_NONE
std::array< ConditionsByEntryMap, CONDITION_SOURCE_TYPE_MAX > ConditionEntriesByTypeArray
@ INSTANCE_INFO_BOSS_STATE
@ INSTANCE_INFO_GUID_DATA
@ CONDITION_NEAR_GAMEOBJECT
@ CONDITION_QUESTREWARDED
@ CONDITION_REALM_ACHIEVEMENT
@ CONDITION_QUEST_OBJECTIVE_PROGRESS
@ CONDITION_OBJECT_ENTRY_GUID_MASTER
@ CONDITION_DAILY_QUEST_DONE
@ CONDITION_TYPE_MASK_MASTER
@ CONDITION_INSTANCE_INFO
@ CONDITION_PRIVATE_OBJECT
@ CONDITION_OBJECT_ENTRY_GUID
@ CONDITION_DIFFICULTY_ID
@ CONDITION_SCENARIO_STEP
@ CONDITION_BATTLE_PET_COUNT
@ CONDITION_REPUTATION_RANK
@ CONDITION_QUEST_COMPLETE
@ CONDITION_ITEM_EQUIPPED
@ CONDITION_SCENE_IN_PROGRESS
@ CONDITION_PLAYER_CONDITION
@ CONDITION_NEAR_CREATURE
@ CONDITION_CREATURE_TYPE
std::unordered_map< uint32, ConditionsByEntryMap > ConditionEntriesByCreatureIdMap
std::vector< Condition * > ConditionContainer
@ RELATION_IN_RAID_OR_PARTY
ConditionEntriesByCreatureIdMap NpcVendorConditionContainerStore
std::unordered_set< uint32 > SpellsUsedInSpellClickConditions
ConditionEntriesByCreatureIdMap VehicleSpellConditionStore
std::vector< Condition * > AllocatedMemoryStore
SmartEventConditionContainer SmartEventConditionStore
ConditionEntriesByTypeArray ConditionStore
ConditionEntriesByCreatureIdMap SpellClickEventConditionStore
ConditionReferenceContainer ConditionReferenceStore
bool HasConditionStringValue1
Condition const * mLastFailedCondition
ConditionSourceInfo(WorldObject *target0, WorldObject *target1=nullptr, WorldObject *target2=nullptr)
ConditionTypes ConditionType
std::string ConditionStringValue1
ConditionSourceType SourceType