How to delete messages in the built-in chat?

Hey! How do I delete a message in the chat from a client’s perspective and/or the server’s persepctive?

This is my current infustructure for creating chat messages on client and server:

local Functions = {}


function Functions.SendMessageToClient(Client:Player,Text:string,Colour:Color3, Font:Enum.Font,SizeMultiplier:number?)
	local ToSendData = {
		Text=Text;
		Font=Font;
		Color = Colour;
		FontSize = 12*(SizeMultiplier or 1);
	}
	game.ReplicatedStorage.ClientChatMessanger:FireClient(Client,ToSendData)
end

function Functions.SendGlobalMessage(Text:string,Colour:Color3,Font:Enum.Font,SizeMultiplier:number?)
	local Data = {
		Text = Text;
		Font = Font;
		Color = Colour;
		FontSize = 12*(SizeMultiplier or 1)
	}
	game.StarterGui:SetCore("ChatMakeSystemMessage",Data)
end
return Functions
local Input = game.ReplicatedStorage.ClientChatMessanger


Input.OnClientEvent:Connect(function(ChatData)
	game.StarterGui:SetCore("ChatMakeSystemMessage",ChatData)
end)

One of my older posts may be helpful:

1 Like

Thanks but I needed to delete the messages globally, not locally. But I already got a solution, I used the method that is used in the thread below:

I like that tutorial too! really nice tutorial.