From 949f089b02939aed58f6d1018021d10d0ae8099e Mon Sep 17 00:00:00 2001 From: Rudolf Polzer Date: Wed, 20 Jul 2011 13:44:55 +0200 Subject: [PATCH] ignore suggested maps if they are in the wrong game type --- qcsrc/server/g_world.qc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/qcsrc/server/g_world.qc b/qcsrc/server/g_world.qc index 9a3533f4c..4e56c0272 100644 --- a/qcsrc/server/g_world.qc +++ b/qcsrc/server/g_world.qc @@ -2361,6 +2361,10 @@ void MapVote_AddVotable(string nextMap, float isSuggestion) for(j = 0; j < mapvote_count; ++j) if(mapvote_maps[j] == nextMap) return; + // suggestions might be no longer valid/allowed after gametype switch! + if(isSuggestion) + if(!MapInfo_CheckMap(nextMap)) + return; if(strlen(nextMap) > mapvote_maxlen) mapvote_maxlen = strlen(nextMap); mapvote_maps[mapvote_count] = strzone(nextMap); -- 2.39.2