Blocking chat clientside

Is it possible to make it so i can block certain players chat clientside? Like, somehow making it so it doesnt display that message?


Like, return false on some hook or another…

You can return an empty string in a **[Gamemode.PlayerSay](** hook, this is servside but it will stop the message coming up for all clients.

Yea, but is it possible clientside?

I don’t see why you would need it clientside, but I guess you could return true in a **[Gamemode.OnPlayerChat](** hook.

That would work? Good. I am making a thing to block players chat that i dont like :smiley:

You could do that serverside.

What if he, you know, doesn’t own the servers he likes to block the visibility of others’ chat messages on?

Then he would do it clientside.


But I don’t think it will work if the server has SE on anyway.

How will we ever bypass with SE
And **[Chat.AddText](**

I did this before (adding and removing people was done by concommand and I even made it write to a file so it carried across sessions) but it was buggy as all get out and custom chat boxes seemed to break it, not to mention most of the popular servers that aren’t RP run scriptenforcer so it’s pointless anyway. Might look to see if I still have it and fix it up.

returning true to OnPlayerChat works great. Thanks.

Not really. I don’t run scriptenforcer on my server because of the kick crash, I’d assume plenty of others don’t as well.

Just block the “se fail” command.

You should edit your server.dll, it’s a very simple fix. I’ll write a module later.