Posted: Tue Mar 23, 2004 9:03 pm
if u manage 2 reach a solution plz tell me as i would love 2 have a script/proram do that 4 me 
No worries! So what are you planning to use cvars for - once you have collected the statistics, do you want to get them back into the map scripts for some reason?Slopester wrote:thx m8.
dunno nuthin bout cvars so gonna do a bit of reading - thx for pointers
Yes, that's correct, you won't need to use cvars for anything. You can't get access to score information within the map script (without using triggers and getting potentially inaccurate information and probably lagSlopester wrote:No. I only want to get the stats out, not back in. Does this mean I don't need any cvars business?
I guess you are talking about TDM or FFA? For those game types, you can query the server in the same way GameSpy does to get the kills/deaths, and not have to parse the log file. Here's the bit I don't like about that method - you have to keep checking the scores table frequently enough that you're going to have gotten it at least once between the time when play ends on one map and the server starts loading the next map (how many seconds is that?). I guess it's not bad, but it just seems a bit messy to meIt would be nice to get end-of-game scores out as the game is clearly doing all the kills/deaths calculations and presenting them at the end of each map. This would save loads of scripting but if the only way to get that data is to monitor each kill/death and do the maths in PHP, I'll have to settle for that.
Sounds like a standard disclaimer I should put on the bottom of everything I sayIf I ever get it going I'll post the script etc... But don't hold your breath!!
If you're writing a program which just uses the query port, there's no way for it to know when the map has ended, except to detect that the server has changed to a new map. If you're parsing the log file, you might be able to detect the game has ended somehow - there might be some message written to the log file like "round over", but I don't think so.M&M wrote:well,y do u have 2 check the server every few seconds ?cant u just get the final results? like say ,when the game ends send final results 2 so and so.
You'd have to start the program which polls the server at exactly the same time as the server, and somehow account for the loading time of each map. That'd be pretty difficult I think.M&M wrote:aha ,well usually the tourneys i run are timebased.so i could prolly set a time limit 2 check the server or something
That mohstats program probably does it, have you looked at it yet?.i dont know much about scripting so i dont prolly know what im talking aboutbut i really would like 2 do something like that .at least something that gathers the score of all players in a ffa ,on several map rotations .
Well I'm not an expert on PHP but I might be able to help you get it working if you can't get it working yourselfM&M wrote:i tried 2 dload it ,but i somehow ended up with a bunch of broken links leading 2 nowhere .i did manage 2 reach the file but i didnt understand how 2 get it onto my harddrive .ill prolly try 2morow as im very tired 2day and i want 2 slleeeeeppp so im not thinking very straight
How's the installation of PHP and mohstats going?M&M wrote:**holds breathe *** **face becomes red ****waiting ** ......
And it's also called stealing !kai0ty wrote:u shud just go to one of the sites u mentioned and look at the source. its probably tyhe easiest way.