The CheckValve Chat Relay includes a few utilities for testing its functionality. Specifically, it includes a utility to send simulated SRCDS log messages to the Chat Relay, as well as a simple client which can connect to the Chat Relay and show relayed messages. These utilities are located in the <INSTALL_DIR>/util directory, and are provided in both Perl and Java.
The UDP message emitter sends a simulated SRCDS log message to the Chat Relay.
Perl usage:
perl udp_message_emitter.pl
Java usage:
java UDPMessageEmitter
Regardless of the invocation, the command-line options are the same:
Command line options:
--to <ip>:<port> Send messages to the listener at the specified IP and port (default = 127.0.0.1:12345)
--from <ip>:<port> Send messages from the specified IP and port (default = 127.0.0.1:2345)
--delay <num> Send a message every <num> seconds (default = 1)
--limit <num> Stop after sending <num> messages (default = no limit)
--message <string> Send <string> as the message text (default = "This is a test!")
--sayteam Make this a say_team message (default = say)
Notes:
You can also use the short options -t, -f, -d, -l, -m, and -s, respectively.
There are no required command-line arguments; the defaults will be used if none are provided.
When using the --from option, the specified address must be assigned to a network interface on the host.
The chat logger opens a client connection to the Chat Relay and displays messages received from the relay.
Perl usage:
perl chat_logger.pl
Java usage:
java ChatLogger
Regardless of the invocation, the command-line options are the same:
Command line options:
--chat-relay <ip>:<port> Connect to the CheckValve Chat Relay at the specified IP and port (required).
--game-server <ip>:<port> Request chat messages from the game server at the specified IP and port (required).
--limit <num> Stop the chat logger after receiving <num> messages.
--password <password> Specify the CheckValve Chat Relay password.
--quiet Suppress connection and status messages.
Notes:
You can also use the short options -c, -g, -l, -p, and -q, respectively.
The Chat Relay (-c or --chat-relay) and game server (-g or --game-server) options are required.
The password option (-p or --password) must be specified if the Chat Relay requires a password for client connections.
The Chat Logger utility will print chat messages to the console. If you wish to log these messages to a file, you must redirect the program's output. On DOS and most Linux shells, this is accomplished using the ">" operator to write to a new file, or the ">>" operator to append to an existing file. The following examples demonstrate logging to a file.
Example: Save chat messages to a new file:
java ChatLogger -c 127.0.0.1:12345 -g 127.0.0.1:27015 -p myPassword -q > chat-messages.txt
Example: Append chat messages to an existing file:
java ChatLogger -c 127.0.0.1:12345 -g 127.0.0.1:27015 -p myPassword -q >> chat-messages.txt
When logging chat message to a file, it may also be preferable to run the Chat Logger as a background process. The following examples demonstrate how this can be accomplished.
Example: Run the Chat Logger as a background process in a Linux shell and save messages to a new file:
java ChatLogger -c 127.0.0.1:12345 -g 127.0.0.1:27015 -p myPassword -q > chat-messages.txt &
Example: Run the Chat Logger as a background process in a DOS shell and save messages to a new file:
START /B java ChatLogger -c 127.0.0.1:12345 -g 127.0.0.1:27015 -p myPassword -q > chat-messages.txt