diff --git a/src/game/game_text.cpp b/src/game/game_text.cpp --- a/src/game/game_text.cpp +++ b/src/game/game_text.cpp @@ -268,9 +268,15 @@ static void ExtractStringParams(const St StringParams ¶m = params.emplace_back(); ParsedCommandStruct pcs = ExtractCommandString(ls->english.c_str(), false); - for (const CmdStruct *cs : pcs.consuming_commands) { - if (cs == nullptr) break; - param.emplace_back(GetParamType(cs), cs->consumes); + for (auto it = pcs.consuming_commands.begin(); it != pcs.consuming_commands.end(); it++) { + if (*it == nullptr) { + /* Skip empty param unless a non empty param exist after it. */ + if (std::all_of(it, pcs.consuming_commands.end(), [](auto cs) { return cs == nullptr; })) break; + param.emplace_back(StringParam::UNUSED, 1, nullptr); + continue; + } + const CmdStruct *cs = *it; + param.emplace_back(GetParamType(cs), cs->consumes, cs->cmd); } } }