1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-16 15:29:55 +00:00

Merge branch 'fix_lua_build' into 'master'

Fix build with Lua 5.4.6

See merge request OpenMW/openmw!3640
This commit is contained in:
Alexei Kotov 2023-12-08 17:26:10 +00:00
commit 102d2c4b43

View file

@ -123,8 +123,8 @@ namespace MWLua
void LuaManager::update()
{
if (Settings::lua().mGcStepsPerFrame > 0)
lua_gc(mLua.sol(), LUA_GCSTEP, Settings::lua().mGcStepsPerFrame);
if (const int steps = Settings::lua().mGcStepsPerFrame; steps > 0)
lua_gc(mLua.sol(), LUA_GCSTEP, steps);
if (mPlayer.isEmpty())
return; // The game is not started yet.