From d1a4c6ad855c3f910412b8ba12497d1aa15a013e Mon Sep 17 00:00:00 2001 From: jacob1 Date: Mon, 25 Sep 2023 20:15:40 -0400 Subject: [PATCH] Fix custom can_move settings being reset after using tpt.el --- src/lua/LegacyLuaAPI.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lua/LegacyLuaAPI.cpp b/src/lua/LegacyLuaAPI.cpp index 93049d1eb..b9702b219 100644 --- a/src/lua/LegacyLuaAPI.cpp +++ b/src/lua/LegacyLuaAPI.cpp @@ -249,7 +249,8 @@ int luacon_elementwrite(lua_State* l) LuaScriptInterface::LuaSetProperty(l, prop, propertyAddress, 3); luacon_model->BuildMenus(); - luacon_sim->init_can_move(); + auto *luacon_ci = static_cast(commandInterface); + luacon_ci->custom_init_can_move(); std::fill(&luacon_ren->graphicscache[0], &luacon_ren->graphicscache[0] + PT_NUM, gcache_item()); return 0;