Core/Player: Vertical "Say" distance
Port From (https://github.com/TrinityCore/TrinityCore/commit/ab77b1d99254855d690670a4654cacec8b12daf6)
This commit is contained in:
@@ -5737,13 +5737,13 @@ namespace Game.Entities
|
||||
Cell.VisitWorldObjects(this, notifier, dist);
|
||||
}
|
||||
|
||||
void SendMessageToSetInRange(ServerPacket data, float dist, bool self, bool own_team_only)
|
||||
void SendMessageToSetInRange(ServerPacket data, float dist, bool self, bool own_team_only, bool required3dDist = false)
|
||||
{
|
||||
if (self)
|
||||
SendPacket(data);
|
||||
|
||||
PacketSenderRef sender = new(data);
|
||||
var notifier = new MessageDistDeliverer<PacketSenderRef>(this, sender, dist, own_team_only);
|
||||
var notifier = new MessageDistDeliverer<PacketSenderRef>(this, sender, dist, own_team_only, null, required3dDist);
|
||||
Cell.VisitWorldObjects(this, notifier, dist);
|
||||
}
|
||||
|
||||
@@ -6000,7 +6000,7 @@ namespace Game.Entities
|
||||
localizer.Invoke(this);
|
||||
|
||||
// Send to players
|
||||
MessageDistDeliverer<LocalizedDo> notifier = new(this, localizer, range);
|
||||
MessageDistDeliverer<LocalizedDo> notifier = new(this, localizer, range, false, null, true);
|
||||
Cell.VisitWorldObjects(this, notifier, range);
|
||||
}
|
||||
|
||||
@@ -6026,7 +6026,7 @@ namespace Game.Entities
|
||||
|
||||
ChatPkt data = new();
|
||||
data.Initialize(ChatMsg.Emote, Language.Universal, this, this, text);
|
||||
SendMessageToSetInRange(data, WorldConfig.GetFloatValue(WorldCfg.ListenRangeTextemote), !GetSession().HasPermission(RBACPermissions.TwoSideInteractionChat));
|
||||
SendMessageToSetInRange(data, WorldConfig.GetFloatValue(WorldCfg.ListenRangeTextemote), true, !GetSession().HasPermission(RBACPermissions.TwoSideInteractionChat), true);
|
||||
}
|
||||
public override void TextEmote(uint textId, WorldObject target = null, bool isBossEmote = false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user