mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-03-10 19:20:32 +00:00
refactor(Core): SendDirectMessage (#23230)
This commit is contained in:
@@ -199,7 +199,7 @@ public:
|
||||
|
||||
WorldPacket data(SMSG_UPDATE_INSTANCE_ENCOUNTER_UNIT, 4);
|
||||
data << uint32(ENCOUNTER_FRAME_REFRESH_FRAMES);
|
||||
_owner->GetSession()->SendPacket(&data);
|
||||
_owner->SendDirectMessage(&data);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -196,7 +196,7 @@ public:
|
||||
data << uint32(VEHICLE_SPELL_RIDE_HARDCODED);
|
||||
data << uint8(SPELL_FAILED_CUSTOM_ERROR);
|
||||
data << uint32(SPELL_CUSTOM_ERROR_MUST_HAVE_LANCE_EQUIPPED);
|
||||
clicker->ToPlayer()->GetSession()->SendPacket(&data);
|
||||
clicker->ToPlayer()->SendDirectMessage(&data);
|
||||
return false;
|
||||
}
|
||||
};
|
||||
|
||||
@@ -2272,7 +2272,7 @@ class spell_igb_overheat_aura : public AuraScript
|
||||
WorldPacket data(SMSG_CLIENT_CONTROL_UPDATE, GetUnitOwner()->GetPackGUID().size() + 1);
|
||||
data << GetUnitOwner()->GetPackGUID();
|
||||
data << uint8(value);
|
||||
player->GetSession()->SendPacket(&data);
|
||||
player->SendDirectMessage(&data);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -375,7 +375,7 @@ void SendPacketToPlayers(WorldPacket const* data, Unit* source)
|
||||
for (Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr)
|
||||
if (Player* player = itr->GetSource())
|
||||
if (player->GetAreaId() == AREA_THE_FROZEN_THRONE)
|
||||
player->GetSession()->SendPacket(data);
|
||||
player->SendDirectMessage(data);
|
||||
}
|
||||
|
||||
struct ShadowTrapLKTargetSelector
|
||||
|
||||
@@ -184,7 +184,7 @@ public:
|
||||
data << spellId;
|
||||
data << uint8(SPELL_FAILED_CUSTOM_ERROR);
|
||||
data << uint32(SPELL_CUSTOM_ERROR_CANT_BUILD_MORE_VEHICLES);
|
||||
player->GetSession()->SendPacket(&data);
|
||||
player->SendDirectMessage(&data);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user