diff options
| author | Alfred Eriksson <somerunce@gmail.com> | 2009-01-13 17:58:16 +0000 |
|---|---|---|
| committer | Alfred Eriksson <somerunce@gmail.com> | 2009-01-13 17:58:16 +0000 |
| commit | fa02f461c73551126d337e3b1eb8ba11dae50d92 (patch) | |
| tree | fe0e403790d139ee69d26dc623e08aaaf8042db7 /src/game/server/gamecontroller.cpp | |
| parent | eb800cbab97553b43ebaf60ec3e428a8c02b1ad4 (diff) | |
| download | zcatch-fa02f461c73551126d337e3b1eb8ba11dae50d92.tar.gz zcatch-fa02f461c73551126d337e3b1eb8ba11dae50d92.zip | |
fixed round count bug
Diffstat (limited to 'src/game/server/gamecontroller.cpp')
| -rw-r--r-- | src/game/server/gamecontroller.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/game/server/gamecontroller.cpp b/src/game/server/gamecontroller.cpp index 4fedeefc..9fcaceae 100644 --- a/src/game/server/gamecontroller.cpp +++ b/src/game/server/gamecontroller.cpp @@ -273,6 +273,10 @@ void GAMECONTROLLER::cyclemap() while(is_separator(buf[i])) i++; + // we rotate to the same map, reset the round count! + if(str_comp_nocase(current_map, buf) == 0) + round_count = -1; + dbg_msg("game", "rotating map to %s", &buf[i]); str_copy(config.sv_map, &buf[i], sizeof(config.sv_map)); } @@ -488,7 +492,7 @@ void GAMECONTROLLER::snap(int snapping_client) gameobj->warmup = warmup; - gameobj->round_num = (strlen(config.sv_maprotation) || config.sv_rounds_per_map > 1) ? config.sv_rounds_per_map : 0; + gameobj->round_num = (strlen(config.sv_maprotation) && config.sv_rounds_per_map) ? config.sv_rounds_per_map : 0; gameobj->round_current = round_count+1; |