mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[8056] Move SMSG_CLEAR_COOLDOWN into function and use it. Other cleanups.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
d97f2bb92f
commit
9b9fe55981
6 changed files with 28 additions and 77 deletions
|
|
@ -11017,33 +11017,6 @@ void Unit::SendPetTalk (uint32 pettalk)
|
|||
((Player*)owner)->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
void Unit::SendPetSpellCooldown (uint32 spellid, time_t cooltime)
|
||||
{
|
||||
Unit* owner = GetOwner();
|
||||
if(!owner || owner->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
WorldPacket data(SMSG_SPELL_COOLDOWN, 8+1+4+4);
|
||||
data << uint64(GetGUID());
|
||||
data << uint8(0x0); // flags (0x1, 0x2)
|
||||
data << uint32(spellid);
|
||||
data << uint32(cooltime);
|
||||
|
||||
((Player*)owner)->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
void Unit::SendPetClearCooldown (uint32 spellid)
|
||||
{
|
||||
Unit* owner = GetOwner();
|
||||
if(!owner || owner->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
WorldPacket data(SMSG_CLEAR_COOLDOWN, 4+8);
|
||||
data << uint32(spellid);
|
||||
data << uint64(GetGUID());
|
||||
((Player*)owner)->GetSession()->SendPacket(&data);
|
||||
}
|
||||
|
||||
void Unit::SendPetAIReaction(uint64 guid)
|
||||
{
|
||||
Unit* owner = GetOwner();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue