1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-06-30 19:11:35 +00:00

Fix before insert index

This commit is contained in:
uramer 2025-05-27 11:56:16 +00:00
parent b7b6a41aec
commit 32169155bb

View file

@ -182,7 +182,7 @@ namespace MWLua
if (index == LuaUi::Layer::count())
throw std::logic_error(
Misc::StringUtils::format("Couldn't insert before non-existent layer %s", beforeName));
LuaUi::Layer::insert(index - 1, name, options);
LuaUi::Layer::insert(index, name, options);
},
"Insert before UI layer");
};