Home » Tiberian Technologies / Blackhand Studios » Tiberian Technologies Forum » Introduction to the SSGM 4.0 TCP Logging System
Introduction to the SSGM 4.0 TCP Logging System [message #434694] |
Fri, 13 August 2010 06:49 |
|
danpaul88
Messages: 5795 Registered: June 2004 Location: England
Karma:
|
General (5 Stars) |
|
|
This topic is intended for bot developers who are interested in supporting SSGM 4.0, which will be released as part of the scripts.dll 4.0 project.
Introduction
The file based logging system under previous versions of SSGM is no longer supported and bots which rely on the ability to read ssgmlog and gamelog files will no longer function correctly. However the renlog files will still be created to allow some limited compatibility with older bots.
Instead, SSGM 4.0 supports a new type of logging which server owners based on a TCP connection between the bot and the server. Once connected to the server bots will receive a steady stream of log messages through the connection.
In order to ease the process of updating bots to the new SSGM logging system it was decided to implement the existing ssgmlog and gamelog messages into the new system in the same format as they used in the old file based logging system. This means that bots can simply point messages to existing parsing procedures without having to significantly rewrite their log handling code.
Protocol
The logging protocol is extremely simple. The first three characters if each message sent through the protocol are digits between 0 and 9 which indicate the message type. The remainder of the message is the log entry. Each message is terminated with the NULL character (0x0).
There are 4 built in message types;
000 - SSGM log messages
001 - Gamelog messages
002 - Renlog messages (a copy of everything written to the renlog files)
003 - Console Output (a copy of everything written to the console, basically a copy of 002 without timestamps)
Here are some examples of messages a bot might receive through the TCP connection;
001[14:06:20] POS;VEHICLE;1500000126;GDI_Ceiling_Gun_AGT;-66;21;9;0;100;100
001[14:06:21] POS;SOLDIER;1500000206;CnC_GDI_MiniGunner_0;-12;27;0;179;100;100
003Total current bandwidth usage for players is 85 kilobits per second
002[14:06:22] Total current bandwidth usage for players is 85 kilobits per second
003Westwood Online mode active since 11/08/2010 - 19:06:54
002[19:18:46] Westwood Online mode active since 11/08/2010 - 19:06:54
Important Note
For reasons which are too complicated to go into at this point the first line of the player_info response (the column headers) is output with a newline character (0xD) at the front of the line. If your bot needs to parse this line and would choke on that character you should use an appropriate function to strip that character out of any messages before forwarding them for parsing.
Configuration
SSGM 4.0 uses a configuration file named ssgm.ini, located in the data folder of the FDS installation. There are two important configuration parameters in this file for the logging system.
[General]
Port=8080
EnableGamelog=true
The port parameter defines the port number on which the server should listen for incoming TCP connections to the logging system and should be different from the RenRem and game ports defined in server.ini. Bots must read the port number from this file (or have it provided to them via config settings) to allow them to connect to the server.
The EnableGamelog option turns the logging system on or off and must be set to true to enable the logging system.
Testing
Right now your probably thinking something along the lines of "yeah, this is great and all, but how can I support something I can't test?". Don't worry, I thought of that problem in advance and have prepared a test server which you may connect your bots to in order to test their handling of the protocol.
Server: 82.11.23.160
TCP Log Port: 37854
You can interact with the test server by joining it (lmsbcdan in WOL or 82.11.23.160:4848 by direct connect) and by joining the IRC channel #tt_ssgm_bottest on irc.n00bstories.com where BRenBot 1.53 is running to help you test your bots responses to the TCP logging information.
Please be aware that this server is for bot testing purposes only and should not be used for normal gameplay... apart from anything else it will probably lag due to being hosted on a fairly slow connection.
Server is now offline due to low demand, if you need the server running again to test your bot(s) please send me a PM and I will load it up again.
More Information / Help
If you need any more information or need help with anything related to this new logging system please reply here or send me a PM on these forums.
Have fun testing!
[Updated on: Sun, 26 September 2010 02:12] Report message to a moderator
|
|
|
|
|
Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: reborn on Fri, 13 August 2010 07:35
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: reborn on Fri, 13 August 2010 07:47
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: halo2pac on Fri, 13 August 2010 08:00
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: reborn on Fri, 13 August 2010 08:02
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: Hitman on Fri, 13 August 2010 08:22
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: reborn on Fri, 13 August 2010 08:31
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: ExEric3 on Fri, 13 August 2010 11:21
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: Omar007 on Fri, 13 August 2010 08:38
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: halo2pac on Fri, 13 August 2010 08:47
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: cAmpa on Fri, 13 August 2010 13:20
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: jonwil on Sat, 14 August 2010 22:44
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: dr3w2 on Tue, 17 August 2010 06:32
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: Ethenal on Tue, 17 August 2010 17:20
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: reborn on Wed, 18 August 2010 00:28
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: halo2pac on Sun, 26 September 2010 11:32
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
|
|
|
Re: Introduction to the SSGM 4.0 TCP Logging System
By: danpaul88 on Sun, 26 September 2010 02:13
|
Goto Forum:
Current Time: Sat Nov 09 08:47:53 MST 2024
Total time taken to generate the page: 0.00891 seconds
|