Module |
|
Header |
/Engine/Source/Runtime/Engine/Public/Slate/SlateGameResources.h |
Include |
#include "Slate/SlateGameResources.h" |
Source |
/Engine/Source/Runtime/Engine/Private/Slate/SlateGameResources.cpp |
static TSharedRef< FSlateGameResources > New
(
const FName & InStyleSetName,
const FString & ScopeToDirectory,
const FString & InBasePath
)
Create a new Slate resource set that is scoped to the ScopeToDirectory.
All paths will be formed as InBasePath + "/" + AssetPath. Lookups will be restricted to ScopeToDirectory. e.g. Resources.Initialize( "/Game/Widgets/SFortChest", "/Game/Widgets" ) Resources.GetBrush( "SFortChest/SomeBrush" ); // Will look up "/Game/Widgets" + "/" + "SFortChest/SomeBrush" = "/Game/Widgets/SFortChest/SomeBrush" Resources.GetBrush( "SSomeOtherWidget/SomeBrush" ); // Will fail because "/Game/Widgets/SSomeOtherWidget/SomeBrush" is outside directory to which we scoped.