Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a delay and warning to g_emptyTeamsSkipMapTime #1225

Open
Gireen opened this issue Oct 8, 2020 · 4 comments
Open

Add a delay and warning to g_emptyTeamsSkipMapTime #1225

Gireen opened this issue Oct 8, 2020 · 4 comments
Labels
T-Improvement Improvement for an existing feature

Comments

@Gireen
Copy link
Member

Gireen commented Oct 8, 2020

When level time is bigger than g_emptyTeamsSkipMapTime the game ends if both teams are empty.

This happens instantly at the moment which is a problem when a single player is trying to change the team, spectates or shortly leaves the server.

Instead, skipping a map could be triggered only when g_emptyTeamsSkipMapTime is reached and there where no players in a team for 8 Minutes or similar.

Additionally could there be a warning message with countdown before the game ends to inform spectators since they are not counted as players here.

@Gireen Gireen added the T-Improvement Improvement for an existing feature label Oct 8, 2020
@illwieckz
Copy link
Member

Another way to do it would be to reimplement g_emptyTeamsSkipMapTime in a way it does not use the game time but another timer that would reset and start when server starts, reset and stop when real player join, and start when the last real player quits.

In fact when g_emptyTeamsSkipMapTime was introduced I first thought it would do that, but when I saw it used the game timer I was like: “well, it would do the job while being simpler so it's ok”.

@illwieckz
Copy link
Member

instead of a timer that would be incremented everytime, we may just store a timestamp when both events occurs:

  • game starts
  • real player leaves a team and no one real players is there

and the game would both verify:

  • if that timestamp is older than current game time minus given timeout
  • there is no real player on a team

If one of those two conditions are false, the game would continue as usual.

@Gireen
Copy link
Member Author

Gireen commented Oct 8, 2020

instead of a timer that would be incremented everytime, we may just store a timestamp

yes

how long would the timeout then be?
if its short like 8 minutes the server would start a new map every 8 minutes.
if its longer like 20 minutes it increases the possibility to join a empty late game when it was left less then 20 minutes ago

@illwieckz
Copy link
Member

Something like 5 or 8 minute for a default is good, I see no need for large time like 20 minute, 20 minute is already wrong to join even if no one player never joined before.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-Improvement Improvement for an existing feature
Projects
None yet
Development

No branches or pull requests

2 participants