Official Soldat Forums

Server Talk => Scripting Discussions and Help => Topic started by: Ratman on March 19, 2017, 07:33:15 pm

Title: Number of Games Played
Post by: Ratman on March 19, 2017, 07:33:15 pm
Hello I am new to scripting and stuck at a spot.

I was wondering how I could keep track of the number of games or amount of time played by each player. The function or procedure would have to count every game/time while playing ctf no matter the team (except if hes specing) and the number would update at the end of each game (or continually if counting time).

I was thinking of using onplayerjoin but cant seem to find a way to keep tracking the time or games for each player.

Thank you!
Title: Re: Number of Games Played
Post by: machina on March 20, 2017, 11:07:44 am
I don't make scripts in Soldat but can't you use a cron-like solution that would fetch a list of players every e.g. 30 seconds?
Title: Re: Number of Games Played
Post by: Ratman on March 20, 2017, 09:12:45 pm
I don't make scripts in Soldat but can't you use a cron-like solution that would fetch a list of players every e.g. 30 seconds?


Sorry I dont think I follow.. do you have any examples perhaps?
Title: Re: Number of Games Played
Post by: machina on March 22, 2017, 06:09:04 pm
I don't make scripts in Soldat but can't you use a cron-like solution that would fetch a list of players every e.g. 30 seconds?
Sorry I dont think I follow.. do you have any examples perhaps?
Well, I'm sure it is possible to fetch a list of players at any time.
Cannot you do something like that?