From fa6b704db4da5aaff31070d36d7cfdfc8e0796bb Mon Sep 17 00:00:00 2001 From: BotoX Date: Fri, 19 Jan 2018 15:36:19 +0100 Subject: [PATCH] mapchooser_extended: honor map limits for automatically nominated maps --- .../scripting/mapchooser_extended.sp | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/mapchooser_extended/scripting/mapchooser_extended.sp b/mapchooser_extended/scripting/mapchooser_extended.sp index f1da0520..a9e27a45 100644 --- a/mapchooser_extended/scripting/mapchooser_extended.sp +++ b/mapchooser_extended/scripting/mapchooser_extended.sp @@ -1144,15 +1144,17 @@ void InitiateVote(MapChange when, Handle inputlist=INVALID_HANDLE) GetArrayString(g_NextMapList, count, map, PLATFORM_MAX_PATH); count++; - if(randomizeList == INVALID_HANDLE) + if(InternalGetMapPlayerRestriction(map) == 0) { - /* Insert the map and increment our count */ - AddMapItem(map); + if(randomizeList == INVALID_HANDLE) + { + /* Insert the map and increment our count */ + AddMapItem(map); + } + else + PushArrayString(randomizeList, map); + i++; } - else - PushArrayString(randomizeList, map); - - i++; //Run out of maps, this will have to do. if(count >= availableMaps)