Update ClientInteriorLayoutManager.cpp

This commit is contained in:
AconiteX
2021-10-03 01:27:04 -04:00
parent 344eddae41
commit f62b7f216e

View File

@@ -28,6 +28,8 @@ namespace ClientInteriorLayoutManagerNamespace
bool ms_disableLazyInteriorLayoutCreation;
bool ms_logApplyInteriorLayoutCreates;
bool ms_disableInteriorLayouts;
void remove();
}
@@ -41,6 +43,8 @@ void ClientInteriorLayoutManager::install(bool const disableLazyInteriorLayoutCr
ms_disableLazyInteriorLayoutCreation = ConfigFile::getKeyBool("ClientGame/ClientInteriorLayoutManager", "disableLazyInteriorLayoutCreation", disableLazyInteriorLayoutCreation);
ms_disableInteriorLayouts = !ConfigFile::getKeyBool("ClientGame", "useInteriorLayoutFiles", true);
DebugFlags::registerFlag(ms_logApplyInteriorLayoutCreates, "ClientGame/ClientInteriorLayoutManager", "logApplyInteriorLayoutCreates");
ExitChain::add(remove, "ClientInteriorLayoutManagerNamespace::remove");
@@ -57,7 +61,7 @@ void ClientInteriorLayoutManagerNamespace::remove()
void ClientInteriorLayoutManager::update()
{
if (ms_disableLazyInteriorLayoutCreation)
if (ms_disableLazyInteriorLayoutCreation || ms_disableInteriorLayouts)
return;
//-- find all visible cells
@@ -131,7 +135,7 @@ void ClientInteriorLayoutManager::applyInteriorLayout(TangibleObject * const tan
{
UNREF(fileName);
if (!ms_disableLazyInteriorLayoutCreation)
if (!ms_disableLazyInteriorLayoutCreation || ms_disableInteriorLayouts)
return;
if (!tangibleObject)