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

Public Member Functions

 at_malfurion_stormrage ()
 
bool OnTrigger (Player *player, const AreaTrigger *) 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
 

Additional Inherited Members

- Protected Member Functions inherited from AreaTriggerScript
 AreaTriggerScript (const char *name)
 
- Protected Member Functions inherited from ScriptObject
 ScriptObject (const char *name)
 
virtual ~ScriptObject ()=default
 

Detailed Description

Constructor & Destructor Documentation

◆ at_malfurion_stormrage()

at_malfurion_stormrage::at_malfurion_stormrage ( )
inline
227: AreaTriggerScript("at_malfurion_stormrage") { }
Definition: ScriptMgr.h:800

Member Function Documentation

◆ OnTrigger()

bool at_malfurion_stormrage::OnTrigger ( Player player,
const AreaTrigger  
)
inlineoverridevirtual

Reimplemented from AreaTriggerScript.

230 {
231 if (player->GetInstanceScript() && !player->FindNearestCreature(NPC_MALFURION_STORMRAGE, 15.0f) &&
233 player->SummonCreature(NPC_MALFURION_STORMRAGE, player->GetPositionX(), player->GetPositionY(), player->GetPositionZ(), -1.52f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 100000);
234 return false;
235 }
@ TEMPSUMMON_TIMED_OR_DEAD_DESPAWN
Definition: Object.h:42
@ QUEST_STATUS_REWARDED
Definition: QuestDef.h:106
@ QUEST_ERANIKUS_TYRANT_OF_DREAMS
Definition: instance_sunken_temple.cpp:220
@ QUEST_THE_CHARGE_OF_DRAGONFLIGHTS
Definition: instance_sunken_temple.cpp:221
@ NPC_MALFURION_STORMRAGE
Definition: sunken_temple.h:51
InstanceScript * GetInstanceScript() const
Definition: Object.cpp:1194
Creature * FindNearestCreature(uint32 entry, float range, bool alive=true) const
Definition: Object.cpp:2394
TempSummon * SummonCreature(uint32 id, const Position &pos, TempSummonType spwtype=TEMPSUMMON_MANUAL_DESPAWN, uint32 despwtime=0, uint32 vehId=0, SummonPropertiesEntry const *properties=nullptr) const
Definition: Object.cpp:2303
float GetPositionZ() const
Definition: Position.h:119
float GetPositionX() const
Definition: Position.h:117
float GetPositionY() const
Definition: Position.h:118
QuestStatus GetQuestStatus(uint32 quest_id) const
Definition: PlayerQuest.cpp:1407

References WorldObject::FindNearestCreature(), WorldObject::GetInstanceScript(), Position::GetPositionX(), Position::GetPositionY(), Position::GetPositionZ(), Player::GetQuestStatus(), NPC_MALFURION_STORMRAGE, QUEST_ERANIKUS_TYRANT_OF_DREAMS, QUEST_STATUS_REWARDED, QUEST_THE_CHARGE_OF_DRAGONFLIGHTS, WorldObject::SummonCreature(), and TEMPSUMMON_TIMED_OR_DEAD_DESPAWN.