PDA

View Full Version : Multiple chats?


Ibanezez
10-09-2014, 22:15
I have a Team Fortress 2 server. Basically my goal right now is to create a plugin where you have 2 separate chats, one being all trade, the other being unusual trade. How would I begin making this?

Features it will have:

> Type !atrade or !utrade to switch chats

> When you switch, have only messages from that specific chatroom show


Is this possible? If so, how would I begin making it?

Powerlord
10-10-2014, 01:12
Is it possible? Yes.

I can think of two ways to do it. The first is to intercept say and say_team commands and manually write the SayText2 usermessages they'd normally send out.

The second (easier?) method would be to intercept the SayText and SayText2 usermessages and then resend them with the appropriate recipients... although you'd have to resend it on a timer as you can't start a second usermessage if the first is still open. While I said this is easier, this would cause problems with any plugins that do processing of these usermessages, such as simple chat colors or tags or whatever.

friagram
10-10-2014, 02:34
Simple chat processor was made for things like this

ddhoward
10-10-2014, 03:18
This is an idea I was tossing around a while ago. Idea came from this (https://forums.alliedmods.net/showthread.php?t=140301) plugin which needs improvement.

I would definitely like to see this plugin.