I tested all my other scripts in the server that are connected with this one by using print and checking if all the Remote Events work, although when it comes to creating a system message the message never appears...

rs = game:GetService("ReplicatedStorage")
remotes = rs:WaitForChild("ExploitDetect")
anti = remotes:WaitForChild("AntiExploit")
local startergui = game:GetService("StarterGui")

local function makemsg(stringmsg, color)
	startergui:SetCore('ChatMakeSystemMessage', {
			Text = stringmsg,
			Color = Color3.fromRGB(255, 0, 0),
		})
end

anti.OnClientEvent:Connect(function(reason, Player)
	if reason == "AutoCatch" then
		makemsg('[Server] ' .. Player.. ' has been kicked for reach scripts!')
				end
		if reason == "Speed" then
		makemsg('[Server] ' .. Player.. ' has been kicked for speeding')
			end
			if reason == "BigFoot" then
		makemsg('[Server] ' ..Player.. ' has been kicked for using big foot exploit.')
			end
			if reason == "lol" then
		makemsg('[Server] ' ..Player.. ' has been kicked for trying to bypass anticheat.')
				end

end)