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

Public Member Functions

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

◆ AreaTrigger_at_last_rites()

AreaTrigger_at_last_rites::AreaTrigger_at_last_rites ( )
inline
208 : AreaTriggerScript("at_last_rites")
209 {
210 }
Definition: AreaTriggerScript.h:24

Member Function Documentation

◆ OnTrigger()

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

Reimplemented from AreaTriggerScript.

213 {
216 if (!(QLR == QUEST_STATUS_INCOMPLETE || QLR == QUEST_STATUS_COMPLETE ||
218 return false;
219
220 WorldLocation pPosition;
221
222 switch (trigger->entry)
223 {
224 case 5332:
225 case 5338:
226 case 5339:
227 pPosition = WorldLocation(571, 3733.68f, 3563.25f, 290.812f, 3.665192f);
228 break;
229 case 5334:
230 pPosition = WorldLocation(571, 3802.38f, 3585.95f, 49.5765f, 0.0f);
231 break;
232 case 5340:
233 if (QBT == QUEST_STATUS_INCOMPLETE)
234 pPosition = WorldLocation(571, 3758, 3562, 345.51f, 0.0f);
235 else
236 pPosition = WorldLocation(571, 3687.91f, 3577.28f, 473.342f, 0.0f);
237 break;
238 default:
239 return false;
240 }
241
242 player->TeleportTo(pPosition);
243
244 return false;
245 }
QuestStatus
Definition: QuestDef.h:99
@ QUEST_STATUS_INCOMPLETE
Definition: QuestDef.h:103
@ QUEST_STATUS_COMPLETE
Definition: QuestDef.h:101
@ QUEST_BREAKING_THROUGH
Definition: areatrigger_scripts.cpp:201
@ QUEST_LAST_RITES
Definition: areatrigger_scripts.cpp:200
Definition: Position.h:251
bool TeleportTo(uint32 mapid, float x, float y, float z, float orientation, uint32 options=0, Unit *target=nullptr, bool newInstance=false)
Definition: Player.cpp:1314
QuestStatus GetQuestStatus(uint32 quest_id) const
Definition: PlayerQuest.cpp:1416

References AreaTrigger::entry, Player::GetQuestStatus(), QUEST_BREAKING_THROUGH, QUEST_LAST_RITES, QUEST_STATUS_COMPLETE, QUEST_STATUS_INCOMPLETE, and Player::TeleportTo().