From 85eea70be41f6ea7f5358aa17e8e004537407e3f Mon Sep 17 00:00:00 2001 From: vaxerski Date: Mon, 3 Oct 2022 16:38:05 +0100 Subject: fix commas in free binds --- src/config/ConfigManager.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/config/ConfigManager.hpp') diff --git a/src/config/ConfigManager.hpp b/src/config/ConfigManager.hpp index 8a167e61..8340ef06 100644 --- a/src/config/ConfigManager.hpp +++ b/src/config/ConfigManager.hpp @@ -72,12 +72,12 @@ struct SAnimationPropertyConfig { class CVarList { public: - CVarList(const std::string& in) { + CVarList(const std::string& in, long unsigned int lastArgNo = 0) { std::string curitem = ""; std::string argZ = in; auto nextItem = [&]() { - auto idx = argZ.find_first_of(','); + auto idx = lastArgNo != 0 && m_vArgs.size() >= lastArgNo - 1 ? std::string::npos : argZ.find_first_of(','); if (idx != std::string::npos) { curitem = argZ.substr(0, idx); -- cgit v1.2.3