AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
EoEDrakeEnterVehicleEvent Class Reference

#include "eye_of_eternity.h"

Inheritance diagram for EoEDrakeEnterVehicleEvent:
BasicEvent

Public Member Functions

 EoEDrakeEnterVehicleEvent (Creature &owner, ObjectGuid playerGUID)
 
bool Execute (uint64, uint32) override
 
- Public Member Functions inherited from BasicEvent
 BasicEvent ()=default
 
virtual ~BasicEvent ()=default
 
virtual bool Execute (uint64, uint32)
 
virtual bool IsDeletable () const
 
virtual void Abort (uint64)
 
void ScheduleAbort ()
 

Private Attributes

Creature_owner
 
ObjectGuid _playerGUID
 

Detailed Description

Constructor & Destructor Documentation

◆ EoEDrakeEnterVehicleEvent()

EoEDrakeEnterVehicleEvent::EoEDrakeEnterVehicleEvent ( Creature owner,
ObjectGuid  playerGUID 
)
inline
113: _owner(owner), _playerGUID(playerGUID) { }
Creature & _owner
Definition: eye_of_eternity.h:116
ObjectGuid _playerGUID
Definition: eye_of_eternity.h:117

Member Function Documentation

◆ Execute()

bool EoEDrakeEnterVehicleEvent::Execute ( uint64  ,
uint32   
)
overridevirtual

Reimplemented from BasicEvent.

25{
27 if (p->IsInWorld() && !p->IsDuringRemoveFromWorld() && !p->isBeingLoaded() && p->FindMap() == _owner.FindMap())
28 {
29 p->CastCustomSpell(60683, SPELLVALUE_BASE_POINT0, 1, &_owner, true);
30 return true;
31 }
33 return true;
34}
@ SPELLVALUE_BASE_POINT0
Definition: SpellDefines.h:113
Player * GetPlayer(Map const *, ObjectGuid const guid)
Definition: ObjectAccessor.cpp:220
void DespawnOrUnsummon(Milliseconds msTimeToDespawn, Seconds forcedRespawnTimer)
Definition: Creature.cpp:2178
Map * FindMap() const
Definition: Object.h:537
Definition: Player.h:1081

References _owner, _playerGUID, Creature::DespawnOrUnsummon(), WorldObject::FindMap(), ObjectAccessor::GetPlayer(), and SPELLVALUE_BASE_POINT0.

Member Data Documentation

◆ _owner

Creature& EoEDrakeEnterVehicleEvent::_owner
private

Referenced by Execute().

◆ _playerGUID

ObjectGuid EoEDrakeEnterVehicleEvent::_playerGUID
private

Referenced by Execute().