Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

How can I disable chatting for a player without removing the entire chat?

Asked by 5 years ago

I asked this yesterday, but it was closed for "not contributing" or something.

I'm looking to script a command that will mute a player without removing the entire chat. Used to you would just enable a player's SuperSafeChat property, but Roblox has since removed it.

I could disable the chat by doing:

game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Chat, false)

But I still want the muted player to see chats other people are sending, without having to script another chat UI.

I've tried hiding the textBox in the CoreGui, but for some reason when the Visible property is false it still functions, so the player is still able to chat.

A way I think will work is checking if the ChatBox is focused and ending it, but I want to know if there's a better way of doing it.

Thanks

1
I think your solution of checking if it's focused would be a great idea User#19524 175 — 5y
1
delete the players text when they chat greatneil80 2647 — 5y
0
You can use this I believe, if you need more help in understanding how to use this function then let me know because its a chat module thing https://wiki.roblox.com/index.php?title=Lua_Chat_System/Server_API/ChatChannel#MuteSpeaker Vulkarin 581 — 5y

1 answer

Log in to vote
-1
Answered by
danglt 185
5 years ago
game.Players.LimitedLogic.PlayerGui.Chat.Frame:Destroy()
Ad

Answer this question