bHideLevelInstanceHierarchy
bHideLevelInstanceHierarchy
#Overview
name: bHideLevelInstanceHierarchy
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 24
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of bHideLevelInstanceHierarchy is to control the visibility of Level Instance content within the Scene Outliner or similar hierarchical views in Unreal Engine 5. This setting variable is primarily used in the context of level management and scene organization.
bHideLevelInstanceHierarchy is utilized by several Unreal Engine subsystems and modules, including:
- SceneOutliner
- ObjectMixer
- LevelInstanceEditor
- DisplayClusterLightCardEditor
- ChaosVD (Chaos Destruction Visualization)
The value of this variable is typically set within the configuration settings of the respective modules or modes. For example, in the FObjectMixerOutlinerMode constructor, it’s set based on the LocalSettings.bHideLevelInstanceHierarchy value.
This variable often interacts with other visibility-related variables such as bHideComponents, bHideUnloadedActors, and bHideEmptyFolders. These variables work together to control the overall visibility and organization of the scene hierarchy.
Developers should be aware that:
- Changing this variable affects the visibility of Level Instance content in the Scene Outliner and similar views.
- It can impact the user’s ability to interact with and select actors within Level Instances.
- The setting may affect performance and scene organization, especially in complex scenes with many nested Level Instances.
Best practices when using this variable include:
- Consider the needs of your specific project when deciding whether to hide or show Level Instance hierarchies.
- Provide a user-friendly way for developers and level designers to toggle this setting if needed.
- Be consistent in its usage across different parts of your project to maintain a coherent user experience.
- When implementing custom outliner or hierarchy views, respect this setting to maintain consistency with the engine’s standard behavior.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEditorPerProjectUserSettings.ini:127, section: [/Script/SceneOutliner.ActorBrowsingModeSettings]
- INI Section:
/Script/SceneOutliner.ActorBrowsingModeSettings
- Raw value:
False
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Plugins/ChaosVD/Source/ChaosVD/Private/ChaosVDWorldOutlinerMode.cpp:192
Scope (from outer to inner):
file
function TUniquePtr<ISceneOutlinerHierarchy> FChaosVDWorldOutlinerMode::CreateHierarchy
Source code excerpt:
ActorHierarchy->SetShowingComponents(!bHideComponents);
ActorHierarchy->SetShowingOnlyActorWithValidComponents(!bHideComponents && bHideActorWithNoComponent);
ActorHierarchy->SetShowingLevelInstances(!bHideLevelInstanceHierarchy);
ActorHierarchy->SetShowingUnloadedActors(!bHideUnloadedActors);
ActorHierarchy->SetShowingEmptyFolders(!bHideEmptyFolders);
return ActorHierarchy;
}
#Loc: <Workspace>/Engine/Plugins/Editor/ObjectMixer/ObjectMixer/Source/ObjectMixer/Private/Views/List/Modes/ObjectMixerOutlinerMode.cpp:357
Scope (from outer to inner):
file
function FObjectMixerOutlinerMode::FObjectMixerOutlinerMode
Source code excerpt:
}), FSceneOutlinerFilter::EDefaultBehaviour::Pass));
bHideLevelInstanceHierarchy = LocalSettings.bHideLevelInstanceHierarchy;
FSceneOutlinerFilterInfo HideLevelInstancesInfo(
LOCTEXT("ToggleHideLevelInstanceContent", "Hide Level Instance Content"),
LOCTEXT("ToggleHideLevelInstancesToolTip", "When enabled, hides all level instance content."),
LocalSettings.bHideLevelInstanceHierarchy,
FCreateSceneOutlinerFilter::CreateStatic(&FObjectMixerOutlinerMode::CreateHideLevelInstancesFilter)
);
HideLevelInstancesInfo.OnToggle().AddLambda([this](bool bIsActive)
{
FObjectMixerOutlinerModeConfig* Settings = GetMutableConfig();
if(Settings)
{
Settings->bHideLevelInstanceHierarchy = bHideLevelInstanceHierarchy = bIsActive;
SaveConfig();
}
if (auto ActorHierarchy = StaticCast<FObjectMixerOutlinerHierarchy*>(Hierarchy.Get()))
{
ActorHierarchy->SetShowingLevelInstances(!bIsActive);
#Loc: <Workspace>/Engine/Plugins/Editor/ObjectMixer/ObjectMixer/Source/ObjectMixer/Private/Views/List/Modes/ObjectMixerOutlinerMode.cpp:388
Scope (from outer to inner):
file
function FObjectMixerOutlinerMode::FObjectMixerOutlinerMode
lambda-function
Source code excerpt:
[this](const AActor* Actor)
{
if (!bHideLevelInstanceHierarchy)
{
if (const ULevelInstanceSubsystem* LevelInstanceSubsystem = RepresentingWorld->GetSubsystem<ULevelInstanceSubsystem>())
{
// if actor has a valid parent and the parent is not being edited,
// then the actor should not be selectable.
if (const ILevelInstanceInterface* ParentLevelInstance = LevelInstanceSubsystem->GetParentLevelInstance(Actor))
#Loc: <Workspace>/Engine/Plugins/Editor/ObjectMixer/ObjectMixer/Source/ObjectMixer/Private/Views/List/Modes/ObjectMixerOutlinerMode.cpp:426
Scope (from outer to inner):
file
function FObjectMixerOutlinerMode::FObjectMixerOutlinerMode
lambda-function
Source code excerpt:
if (bInCheckHideLevelInstanceFlag)
{
return !bHideLevelInstanceHierarchy;
}
}
if (ULevel* Level = Cast<ULevel>(InFolder.GetRootObjectPtr()))
{
return true;
}
#Loc: <Workspace>/Engine/Plugins/Editor/ObjectMixer/ObjectMixer/Source/ObjectMixer/Private/Views/List/Modes/ObjectMixerOutlinerMode.cpp:905
Scope (from outer to inner):
file
function TUniquePtr<ISceneOutlinerHierarchy> FObjectMixerOutlinerMode::CreateHierarchy
Source code excerpt:
OutlinerHierarchy->SetShowingComponents(!bHideComponents);
OutlinerHierarchy->SetShowingOnlyActorWithValidComponents(!bHideComponents && bHideActorWithNoComponent);
OutlinerHierarchy->SetShowingLevelInstances(!bHideLevelInstanceHierarchy);
OutlinerHierarchy->SetShowingUnloadedActors(!bHideUnloadedActors);
OutlinerHierarchy->SetShowingEmptyFolders(!bHideEmptyFolders);
return OutlinerHierarchy;
}
#Loc: <Workspace>/Engine/Plugins/Editor/ObjectMixer/ObjectMixer/Source/ObjectMixer/Public/Views/List/Modes/ObjectMixerOutlinerMode.h:87
Scope: file
Source code excerpt:
/** True when the Scene Outliner is not displaying LevelInstances */
UPROPERTY()
bool bHideLevelInstanceHierarchy = false;
/** True when the Scene Outliner is not displaying unloaded actors */
UPROPERTY()
bool bHideUnloadedActors = false;
/** True when the Scene Outliner is not displaying empty folders */
#Loc: <Workspace>/Engine/Plugins/Runtime/nDisplay/Source/DisplayClusterLightCardEditor/Private/Outliner/DisplayClusterLightCardOutlinerMode.cpp:108
Scope (from outer to inner):
file
function FDisplayClusterLightCardOutlinerMode::FDisplayClusterLightCardOutlinerMode
Source code excerpt:
TWeakPtr<SDisplayClusterLightCardOutliner> InLightCardOutliner, TWeakObjectPtr<UWorld> InSpecifiedWorldToDisplay)
: FActorMode(FActorModeParams(InSceneOutliner, InSpecifiedWorldToDisplay,
/* bHideComponents */ true, /* bHideLevelInstanceHierarchy */ true, /* bHideUnloadedActors */ true, /* bHideEmptyFolders */ true)),
LightCardOutliner(InLightCardOutliner)
{
FEditorDelegates::OnEditCutActorsBegin.AddRaw(this, &FDisplayClusterLightCardOutlinerMode::OnEditCutActorsBegin);
FEditorDelegates::OnEditCutActorsEnd.AddRaw(this, &FDisplayClusterLightCardOutlinerMode::OnEditCutActorsEnd);
FEditorDelegates::OnEditCopyActorsBegin.AddRaw(this, &FDisplayClusterLightCardOutlinerMode::OnEditCopyActorsBegin);
FEditorDelegates::OnEditCopyActorsEnd.AddRaw(this, &FDisplayClusterLightCardOutlinerMode::OnEditCopyActorsEnd);
#Loc: <Workspace>/Engine/Source/Editor/LevelInstanceEditor/Private/SLevelInstancePivotPicker.cpp:31
Scope (from outer to inner):
file
function void SLevelInstancePivotPicker::Construct
lambda-function
Source code excerpt:
Params.SceneOutliner = Outliner;
Params.bHideComponents = true;
Params.bHideLevelInstanceHierarchy = false;
Params.bHideUnloadedActors = true;
Params.bHideEmptyFolders = true;
Params.bCanInteractWithSelectableActorsOnly = false;
return new FActorPickingMode(Params, OnItemPicked);
});
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingMode.cpp:63
Scope (from outer to inner):
file
function FActorBrowsingMode::FActorBrowsingMode
Source code excerpt:
FActorBrowsingMode::FActorBrowsingMode(SSceneOutliner* InSceneOutliner, TWeakObjectPtr<UWorld> InSpecifiedWorldToDisplay)
: FActorModeInteractive(FActorModeParams(InSceneOutliner, InSpecifiedWorldToDisplay, /* bHideComponents */ true, /* bHideLevelInstanceHierarchy */ false, /* bHideUnloadedActors */ false, /* bHideEmptyFolders */ false))
, FilteredActorCount(0)
{
WorldPartitionEditorModule = FModuleManager::GetModulePtr<IWorldPartitionEditorModule>("WorldPartitionEditor");
// Capture selection changes of bones from mesh selection in fracture tools
FSceneOutlinerDelegates::Get().OnComponentsUpdated.AddRaw(this, &FActorBrowsingMode::OnComponentsUpdated);
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingMode.cpp:103
Scope (from outer to inner):
file
function FActorBrowsingMode::FActorBrowsingMode
Source code excerpt:
}
bHideLevelInstanceHierarchy = LocalSettings.bHideLevelInstanceHierarchy;
InSceneOutliner->SetShowTransient(!LocalSettings.bHideTemporaryActors);
// Get the OutlinerModule to register FilterInfos with the FilterInfoMap
FSceneOutlinerFilterInfo ShowOnlySelectedActorsInfo(LOCTEXT("ToggleShowOnlySelected", "Only Selected"), LOCTEXT("ToggleShowOnlySelectedToolTip", "When enabled, only displays actors that are currently selected."), LocalSettings.bShowOnlySelectedActors, FCreateSceneOutlinerFilter::CreateStatic(&FActorBrowsingMode::CreateShowOnlySelectedActorsFilter));
ShowOnlySelectedActorsInfo.OnToggle().AddLambda([this](bool bIsActive)
{
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingMode.cpp:257
Scope (from outer to inner):
file
function FActorBrowsingMode::FActorBrowsingMode
lambda-function
Source code excerpt:
}
if (!bHideLevelInstanceHierarchy)
{
if (const ULevelInstanceSubsystem* LevelInstanceSubsystem = RepresentingWorld->GetSubsystem<ULevelInstanceSubsystem>())
{
// if actor has a valid parent and the parent is not being edited,
// then the actor should not be selectable.
if (const ILevelInstanceInterface* ParentLevelInstance = LevelInstanceSubsystem->GetParentLevelInstance(Actor))
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingMode.cpp:448
Scope (from outer to inner):
file
function void FActorBrowsingMode::OnToggleHideLevelInstanceHierarchy
Source code excerpt:
void FActorBrowsingMode::OnToggleHideLevelInstanceHierarchy()
{
bHideLevelInstanceHierarchy = !bHideLevelInstanceHierarchy;
FActorBrowsingModeConfig* Settings = GetMutableConfig();
if (Settings)
{
Settings->bHideLevelInstanceHierarchy = bHideLevelInstanceHierarchy;
SaveConfig();
}
if (auto ActorHierarchy = StaticCast<FActorHierarchy*>(Hierarchy.Get()))
{
ActorHierarchy->SetShowingLevelInstances(!bHideLevelInstanceHierarchy);
}
SceneOutliner->FullRefresh();
}
bool FActorBrowsingMode::ShouldHideLevelInstanceHierarchy() const
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingMode.cpp:471
Scope (from outer to inner):
file
function bool FActorBrowsingMode::ShouldHideLevelInstanceHierarchy
Source code excerpt:
if (Settings)
{
return Settings->bHideLevelInstanceHierarchy;
}
return false;
}
void FActorBrowsingMode::InitializeViewMenuExtender(TSharedPtr<FExtender> Extender)
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorBrowsingModeSettings.h:55
Scope: file
Source code excerpt:
/** True when the Scene Outliner is not displaying LevelInstances */
UPROPERTY()
bool bHideLevelInstanceHierarchy = false;
/** True when the Scene Outliner is not displaying unloaded actors */
UPROPERTY()
bool bHideUnloadedActors = false;
/** True when the Scene Outliner is not displaying empty folders */
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorMode.cpp:116
Scope (from outer to inner):
file
function FActorMode::FActorMode
Source code excerpt:
, bHideComponents(Params.bHideComponents)
, bHideActorWithNoComponent(Params.bHideActorWithNoComponent)
, bHideLevelInstanceHierarchy(Params.bHideLevelInstanceHierarchy)
, bHideUnloadedActors(Params.bHideUnloadedActors)
, bHideEmptyFolders(Params.bHideEmptyFolders)
, bCanInteractWithSelectableActorsOnly(Params.bCanInteractWithSelectableActorsOnly)
{
SceneOutliner->AddFilter(MakeShared<FActorFilter>(FActorTreeItem::FFilterPredicate::CreateLambda([this](const AActor* Actor)
{
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorMode.cpp:136
Scope (from outer to inner):
file
function FActorMode::FActorMode
lambda-function
Source code excerpt:
if (bInCheckHideLevelInstanceFlag)
{
return !bHideLevelInstanceHierarchy;
}
}
if (ULevel* Level = Cast<ULevel>(InFolder.GetRootObjectPtr()))
{
return true;
}
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorMode.cpp:166
Scope (from outer to inner):
file
function TUniquePtr<ISceneOutlinerHierarchy> FActorMode::CreateHierarchy
Source code excerpt:
ActorHierarchy->SetShowingComponents(!bHideComponents);
ActorHierarchy->SetShowingOnlyActorWithValidComponents(!bHideComponents && bHideActorWithNoComponent);
ActorHierarchy->SetShowingLevelInstances(!bHideLevelInstanceHierarchy);
ActorHierarchy->SetShowingUnloadedActors(!bHideUnloadedActors);
ActorHierarchy->SetShowingEmptyFolders(!bHideEmptyFolders);
return ActorHierarchy;
}
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/ActorMode.cpp:338
Scope (from outer to inner):
file
function bool FActorMode::IsActorDisplayable
Source code excerpt:
bool FActorMode::IsActorDisplayable(const AActor* Actor) const
{
return FActorMode::IsActorDisplayable(SceneOutliner, Actor, !bHideLevelInstanceHierarchy);
}
FFolder::FRootObject FActorMode::GetRootObject() const
{
return FFolder::GetWorldRootFolder(RepresentingWorld.Get()).GetRootObject();
}
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/SceneOutlinerModule.cpp:102
Scope (from outer to inner):
file
function TSharedRef<ISceneOutliner> FSceneOutlinerModule::CreateActorPicker
lambda-function
Source code excerpt:
Params.SpecifiedWorldToDisplay = SpecifiedWorld;
Params.bHideComponents = true;
Params.bHideLevelInstanceHierarchy = bInHideLevelInstanceHierarchy;
Params.bHideUnloadedActors = true;
Params.bHideEmptyFolders = true;
return new FActorPickingMode(Params, OnItemPicked);
});
InitOptions.ModeFactory = ModeFactory;
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Private/SceneOutlinerModule.cpp:141
Scope (from outer to inner):
file
function TSharedRef<ISceneOutliner> FSceneOutlinerModule::CreateComponentPicker
lambda-function
Source code excerpt:
Params.bHideComponents = false;
Params.bHideActorWithNoComponent = true;
Params.bHideLevelInstanceHierarchy = true;
Params.bHideUnloadedActors = true;
Params.bHideEmptyFolders = true;
return new FActorPickingMode(Params, OnItemPicked);
});
FSceneOutlinerInitializationOptions InitOptions(InInitOptions);
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Public/ActorMode.h:39
Scope (from outer to inner):
file
function FActorModeParams
Source code excerpt:
, SceneOutliner(InSceneOutliner)
, bHideComponents(bInHideComponents)
, bHideLevelInstanceHierarchy(bInHideLevelInstanceHierarchy)
, bHideUnloadedActors(bInHideUnloadedActors)
, bHideEmptyFolders(bInHideEmptyFolders)
, bCanInteractWithSelectableActorsOnly(bInCanInteractWithSelectableActorsOnly)
{}
TWeakObjectPtr<UWorld> SpecifiedWorldToDisplay = nullptr;
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Public/ActorMode.h:49
Scope: file
Source code excerpt:
bool bHideComponents = true;
bool bHideActorWithNoComponent = false;
bool bHideLevelInstanceHierarchy = true;
bool bHideUnloadedActors = true;
bool bHideEmptyFolders = true;
bool bCanInteractWithSelectableActorsOnly = true;
};
class SCENEOUTLINER_API FActorMode : public ISceneOutlinerMode
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Public/ActorMode.h:124
Scope (from outer to inner):
file
class class FActorMode : public ISceneOutlinerMode
Source code excerpt:
bool bHideActorWithNoComponent;
/** Should the level instance hierarchy be hidden */
bool bHideLevelInstanceHierarchy;
/** Should unloaded actors be hidden */
bool bHideUnloadedActors;
/** Should empty folders be hidden */
bool bHideEmptyFolders;
/** Should the outliner scroll to the item on selection */
bool bAlwaysFrameSelection;
#Loc: <Workspace>/Engine/Source/Editor/SceneOutliner/Public/SceneOutlinerModule.h:46
Scope (from outer to inner):
file
class class FSceneOutlinerModule : public IModuleInterface
Source code excerpt:
const FSceneOutlinerInitializationOptions& InInitOptions,
const FOnActorPicked& OnActorPickedDelegate,
TWeakObjectPtr<UWorld> SpecifiedWorld = nullptr, bool bHideLevelInstanceHierarchy = true) const;
/** Creates a component picker widget. Calls the OnComponentPickedDelegate when an item is selected. */
virtual TSharedRef<ISceneOutliner> CreateComponentPicker(
const FSceneOutlinerInitializationOptions& InInitOptions,
const FOnComponentPicked& OnComponentPickedDelegate,
TWeakObjectPtr<UWorld> SpecifiedWorld = nullptr) const;