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
1654: _player(player) { }
Player * _player
Definition spell_item.cpp:1678

Member Function Documentation

◆ Execute()

bool PartyTimeEmoteEvent::Execute ( uint64  ,
uint32   
)
inlineoverridevirtual

Reimplemented from BasicEvent.

1657 {
1659 {
1660 return true;
1661 }
1662
1663 if (_player->isMoving())
1664 {
1666 }
1667 else
1668 {
1670 }
1671
1672 _player->m_Events.AddEventAtOffset(this, RAND(5s, 10s, 15s));
1673
1674 return false; // do not delete re-added event in EventProcessor::Update
1675 }
static First const & RAND(First const &first, Second const &second, Rest const &... rest)
Definition CreatureAIImpl.h:25
@ EMOTE_ONESHOT_APPLAUD
Definition SharedDefines.h:1924
@ EMOTE_ONESHOT_LAUGH
Definition SharedDefines.h:1914
@ EMOTE_ONESHOT_CHEER
Definition SharedDefines.h:1909
@ EMOTE_ONESHOT_CHICKEN
Definition SharedDefines.h:1922
@ EMOTE_ONESHOT_DANCESPECIAL
Definition SharedDefines.h:2007
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:5789
bool isMoving() const
Definition Unit.h:1663
void HandleEmoteCommand(uint32 emoteId)
Definition Unit.cpp:2035
EventProcessor m_Events
Definition Object.h:731
@ SPELL_PARTY_TIME
Definition spell_item.cpp:1619

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: