AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
PartyTimeEmoteEvent Class Reference
Inheritance diagram for PartyTimeEmoteEvent:
BasicEvent

Public Member Functions

 PartyTimeEmoteEvent (Player *player)
 
bool Execute (uint64, uint32) override
 
- Public Member Functions inherited from BasicEvent
 BasicEvent ()=default
 
virtual ~BasicEvent ()=default
 
virtual bool IsDeletable () const
 
virtual void Abort (uint64)
 
void ScheduleAbort ()
 

Private Attributes

Player * _player
 

Detailed Description

Constructor & Destructor Documentation

◆ PartyTimeEmoteEvent()

PartyTimeEmoteEvent::PartyTimeEmoteEvent ( Player *  player)
inline
1840: _player(player) { }
Player * _player
Definition spell_item.cpp:1864

Member Function Documentation

◆ Execute()

bool PartyTimeEmoteEvent::Execute ( uint64  ,
uint32   
)
inlineoverridevirtual

Reimplemented from BasicEvent.

1843 {
1845 {
1846 return true;
1847 }
1848
1849 if (_player->isMoving())
1850 {
1852 }
1853 else
1854 {
1856 }
1857
1858 _player->m_Events.AddEventAtOffset(this, RAND(5s, 10s, 15s));
1859
1860 return false; // do not delete re-added event in EventProcessor::Update
1861 }
static First const & RAND(First const &first, Second const &second, Rest const &... rest)
Definition CreatureAIImpl.h:25
@ EMOTE_ONESHOT_APPLAUD
Definition SharedDefines.h:1917
@ EMOTE_ONESHOT_LAUGH
Definition SharedDefines.h:1907
@ EMOTE_ONESHOT_CHEER
Definition SharedDefines.h:1902
@ EMOTE_ONESHOT_CHICKEN
Definition SharedDefines.h:1915
@ EMOTE_ONESHOT_DANCESPECIAL
Definition SharedDefines.h:2000
void AddEventAtOffset(BasicEvent *event, Milliseconds offset, uint8 eventGroup=0)
Definition EventProcessor.h:108
bool HasAura(uint32 spellId, ObjectGuid casterGUID=ObjectGuid::Empty, ObjectGuid itemCasterGUID=ObjectGuid::Empty, uint8 reqEffMask=0) const
Definition Unit.cpp:5764
bool isMoving() const
Definition Unit.h:1715
void HandleEmoteCommand(uint32 emoteId)
Definition Unit.cpp:2198
EventProcessor m_Events
Definition Object.h:749
@ SPELL_PARTY_TIME
Definition spell_item.cpp:1805

References _player, EventProcessor::AddEventAtOffset(), EMOTE_ONESHOT_APPLAUD, EMOTE_ONESHOT_CHEER, EMOTE_ONESHOT_CHICKEN, EMOTE_ONESHOT_DANCESPECIAL, EMOTE_ONESHOT_LAUGH, Unit::HandleEmoteCommand(), Unit::HasAura(), Unit::isMoving(), WorldObject::m_Events, RAND(), and SPELL_PARTY_TIME.

Member Data Documentation

◆ _player

Player* PartyTimeEmoteEvent::_player
private

Referenced by Execute().


The documentation for this class was generated from the following file: