Hello all! I want to know how I could be able to make it so that chat the NPCs send can only be seen by players in a certain radius. To clarify, I want the player’s talking to function as normal, but NPC chat to only be able to be seen by certain people in a distance. (Custom chat?)
If there is no solution to the problem, then I’d also love some help on setting up a chat system where people in a certain radius can only see chat of anyone near them (for both players and NPCs). I did find this post, however some replies say that the system is outdated and does not work.
My base NPC chat code:
local speaker = Chat:AddSpeaker("Dummy") -- Chat is defined above
speaker:JoinChannel("All")
speaker:SetExtraData("NameColor", Color3.fromRGB(255, 0, 0))
speaker:SetExtraData("ChatColor", Color3.fromRGB(255, 0, 0))
while true do
wait(1)
speaker:SayMessage("Message", "All")
end
Thanks! All help on this is much appreciated.