From 87eb5ef2aa307b70eefc45861aec5530f585bf87 Mon Sep 17 00:00:00 2001 From: BotoX Date: Sun, 22 Dec 2019 20:52:24 +0100 Subject: [PATCH] mapchooser_extended: fix nomlist VIP/name collision --- .../scripting/nominations_extended.sp | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/mapchooser_extended/scripting/nominations_extended.sp b/mapchooser_extended/scripting/nominations_extended.sp index 02a48fe7..02adaaa6 100644 --- a/mapchooser_extended/scripting/nominations_extended.sp +++ b/mapchooser_extended/scripting/nominations_extended.sp @@ -764,15 +764,17 @@ bool PopulateNominateListMenu(Menu menu, int client, const char[] filter = "") if(!filter[0] || StrContains(map, filter, false) != -1) { - int owner = GetArrayCell(OwnerList, i); - if(!owner) - Format(display, sizeof(display), "%s (Admin)", map); - else - Format(display, sizeof(display), "%s (%N)", map, owner); + strcopy(display, sizeof(display), map); bool VIPRestriction = GetMapVIPRestriction(map); if((VIPRestriction) && AreRestrictionsActive()) - Format(display, sizeof(display), "%s (%T)", map, "VIP Nomination", client); + Format(display, sizeof(display), "%s (%T)", display, "VIP Nomination", client); + + int owner = GetArrayCell(OwnerList, i); + if(!owner) + Format(display, sizeof(display), "%s (Admin)", display); + else + Format(display, sizeof(display), "%s (%N)", display, owner); AddMenuItem(menu, map, display); }