AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
achievement_thorim_lose_your_illusion Class Reference
Inheritance diagram for achievement_thorim_lose_your_illusion:
AchievementCriteriaScript ScriptObject

Public Member Functions

 achievement_thorim_lose_your_illusion ()
 
bool OnCheck (Player *player, Unit *, uint32) override
 
- Public Member Functions inherited from AchievementCriteriaScript
bool IsDatabaseBound () const override
 
virtual bool OnCheck (Player *, Unit *, uint32)
 
- Public Member Functions inherited from ScriptObject
virtual bool IsDatabaseBound () const
 
virtual bool isAfterLoadScript () const
 
virtual void checkValidity ()
 
const std::string & GetName () const
 
uint16 GetTotalAvailableHooks ()
 

Additional Inherited Members

- Protected Member Functions inherited from AchievementCriteriaScript
 AchievementCriteriaScript (const char *name)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name, uint16 totalAvailableHooks=0)
 
virtual ~ScriptObject ()=default
 

Detailed Description

Constructor & Destructor Documentation

◆ achievement_thorim_lose_your_illusion()

achievement_thorim_lose_your_illusion::achievement_thorim_lose_your_illusion ( )
inline
1784: AchievementCriteriaScript("achievement_thorim_lose_your_illusion") {}
Definition: AchievementCriteriaScript.h:24

Member Function Documentation

◆ OnCheck()

bool achievement_thorim_lose_your_illusion::OnCheck ( Player player,
Unit ,
uint32   
)
inlineoverridevirtual

Reimplemented from AchievementCriteriaScript.

1787 {
1788 if (InstanceScript* instance = player->GetInstanceScript())
1789 if (Creature* cr = ObjectAccessor::GetCreature(*player, instance->GetGuidData(TYPE_THORIM)))
1790 return cr->AI()->GetData(DATA_LOSE_YOUR_ILLUSION);
1791
1792 return false;
1793 }
@ TYPE_THORIM
Definition: ulduar.h:42
@ DATA_LOSE_YOUR_ILLUSION
Definition: boss_thorim.cpp:321
Creature * GetCreature(WorldObject const &u, ObjectGuid const guid)
Definition: ObjectAccessor.cpp:210
Definition: Creature.h:43
InstanceScript * GetInstanceScript() const
Definition: Object.cpp:1203
Definition: InstanceScript.h:142

References DATA_LOSE_YOUR_ILLUSION, ObjectAccessor::GetCreature(), WorldObject::GetInstanceScript(), and TYPE_THORIM.