Saving player scores and weapon stats before map change
I want to save the full statistics for each match played on the server in a database, as a json that I can load and display on a web page later. (I can handle this part myself)
I want to track as much information as possible: - basic stats like: kills, deaths , headshots etc - individual weapon stats Players come and go, so I also want to save the stats for the players that played only a few rounds and left. (players that were not online at the map change) What is the best approach for doing this? Can I detect when the map changes? Do I have time to do a POST request to my web server? Should I keep all the statistics in a giant array? How do other plugins do this? (hlstats, psychostats) |
Re: Saving player scores and weapon stats before map change
Never used Psychostats, but HLSTATSX uses a separate demon. It is a 3 step process.
I like this method as sending data directly to the database may lead to game server performance degradation. On top all servers create logs which already keep track of kills and what not, so its convenient to use it rather than re-implementing the whole tracker. Hope that helps. |
Re: Saving player scores and weapon stats before map change
I want to do the same thing like HLSTATSX.
Either send data to a TCP server or do a HTTP POST to a web page. Where can I find the HLSTATS plugin to see how they implemented this? |
Re: Saving player scores and weapon stats before map change
Quote:
I was also thinking of making a live preview of the game: - live scoreboard - a picture of the map with player icons on it, so you can know their location (with some delay to prevent cheating) - this means I would also need to send the player positions every 5 seconds - a live log with kills and other events |
Re: Saving player scores and weapon stats before map change
It uses UDP as far as I know. As for how to get the data you can take a look at HLXSTATS demon yourself.
Here is a sample from parsed HLXSTATS demon log. PHP Code:
|
Re: Saving player scores and weapon stats before map change
Why don't you use SQL to save up data ingame and then use the webpage to display out the data from the database? It would be much simpler.
|
Re: Saving player scores and weapon stats before map change
Quote:
|
Re: Saving player scores and weapon stats before map change
|
| All times are GMT -4. The time now is 15:36. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.