drfreeze123 / amxx-plugin-galileo

Automatically exported from code.google.com/p/amxx-plugin-galileo
0 stars 0 forks source link

Changes to emptyserver map when server is not empty #47

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

What steps will reproduce the problem?
1. Enable the gal_emptyserver_wait option (i had 15 minutes
2. Server emptys (even for just a few seconds)
3. After step two takes place, the map will change without vote to the start of 
your gal_emptyserver_mapfile list

What is the expected output? What do you see instead?
If the server isn't empty it should not change the map without voting

What version of the product are you using? On what operating system?
1.1.290_REV_105, 4-23-2011, Windows 7

Please provide any additional information below.
I discovered this because on my conc server there are usually very few people 
on.  I have reports of (and was able to reproduce) this problem which can be 
very frustrating when you are grinding your way through a concmap.

Welcome back to the project and thank you for your time and plugin!

Original issue reported on code.google.com by robbin...@yahoo.com on 29 Jun 2012 at 7:19

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
I forgot to mention that the plugin does wait the gal_emptyserver_wait time (15 
minutes in my case) after the the server empties before changing the map...but 
the server should be empty for that entire 15 minute period before changing 
without a vote.  Certainly it should not take this action when the server is 
occupied.

Original comment by robbin...@yahoo.com on 18 Aug 2012 at 10:53

GoogleCodeExporter commented 9 years ago
When a user connects you ensure cvar_emptyCycle is reset but never kill the 
task which will eventually change the server to the empty cycle (after time 
elapsed set by cvar gal_emptyserver_wait).  The task is 

     set_task(float(waitMinutes * 60), "srv_startEmptyCycle", TASKID_EMPTYSERVER);

This task is set by function srv_startEmptyCountdown when server becomes empty 
or if its empty at map start. I added the line noted in the function below 
which I believe corrects the issue. This removes the above task when a user 
connects.

public client_connect(id)
{
  set_pcvar_num(cvar_emptyCycle, 0);
  remove_task(TASKID_EMPTYSERVER);  // added to fix auto change when server not empty
  vote_unrock(id);
}

Original comment by robbin...@yahoo.com on 18 Aug 2012 at 10:59

GoogleCodeExporter commented 9 years ago
Thank you for researching this. Your fix was pretty spot on. 

While investigating, I did find another issue in that even if a single player 
was connected, Galileo would still consider the server empty. This was due to 
some poorly written debugging code. I went ahead and took care of that at the 
same time.

Original comment by jones.p....@gmail.com on 19 Feb 2015 at 9:52

GoogleCodeExporter commented 9 years ago
This issue was closed by revision r111.

Original comment by jones.p....@gmail.com on 19 Feb 2015 at 10:04