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

Public Member Functions

 AreaTrigger_at_celestial_planetarium_enterance ()
 
bool OnTrigger (Player *player, AreaTrigger const *) override
 
- Public Member Functions inherited from AreaTriggerScript
bool IsDatabaseBound () const override
 
virtual bool OnTrigger (Player *, AreaTrigger const *)
 
- 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 AreaTriggerScript
 AreaTriggerScript (const char *name)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name, uint16 totalAvailableHooks=0)
 
virtual ~ScriptObject ()=default
 

Detailed Description

Constructor & Destructor Documentation

◆ AreaTrigger_at_celestial_planetarium_enterance()

AreaTrigger_at_celestial_planetarium_enterance::AreaTrigger_at_celestial_planetarium_enterance ( )
inline
523 : AreaTriggerScript("at_celestial_planetarium_enterance")
524 {
525 }
Definition: AreaTriggerScript.h:24

Member Function Documentation

◆ OnTrigger()

bool AreaTrigger_at_celestial_planetarium_enterance::OnTrigger ( Player player,
AreaTrigger const *   
)
inlineoverridevirtual

Reimplemented from AreaTriggerScript.

528 {
529 if (player->IsAlive())
530 if (uint32 questId = (player->GetMap()->Is25ManRaid() ? 13816 : 13607 /*QUEST_CELESTIAL_PLANETARIUM*/))
531 if (player->GetQuestStatus(questId) == QUEST_STATUS_INCOMPLETE)
532 player->AreaExploredOrEventHappens(questId);
533 return false;
534 }
std::uint32_t uint32
Definition: Define.h:107
@ QUEST_STATUS_INCOMPLETE
Definition: QuestDef.h:103
Map * GetMap() const
Definition: Object.h:531
void AreaExploredOrEventHappens(uint32 questId)
Definition: PlayerQuest.cpp:1785
QuestStatus GetQuestStatus(uint32 quest_id) const
Definition: PlayerQuest.cpp:1424
bool IsAlive() const
Definition: Unit.h:1204
bool Is25ManRaid() const
Definition: Map.h:453

References Player::AreaExploredOrEventHappens(), WorldObject::GetMap(), Player::GetQuestStatus(), Map::Is25ManRaid(), Unit::IsAlive(), and QUEST_STATUS_INCOMPLETE.