Moved IsStaticLightingAllowed() to RenderUtils.h and replaced relevant usage.

#rb ola.olsson

[CL 27557666 by tiago costa in ue5-main branch]
This commit is contained in:
tiago costa
2023-09-01 12:07:26 -04:00
parent 9aae65b4fa
commit 62242df915
42 changed files with 78 additions and 197 deletions

View File

@@ -780,11 +780,8 @@ void FLevelEditorActionCallbacks::BuildLightingOnly_Execute()
}
bool FLevelEditorActionCallbacks::BuildLighting_CanExecute()
{
static const auto AllowStaticLightingVar = IConsoleManager::Get().FindTConsoleVariableDataInt(TEXT("r.AllowStaticLighting"));
const bool bAllowStaticLighting = (!AllowStaticLightingVar || AllowStaticLightingVar->GetValueOnGameThread() != 0);
return bAllowStaticLighting && CanBuildLighting() && CanBuildReflectionCaptures();
{
return IsStaticLightingAllowed() && CanBuildLighting() && CanBuildReflectionCaptures();
}
void FLevelEditorActionCallbacks::BuildReflectionCapturesOnly_Execute()