Navigation
API > API/Runtime > API/Runtime/Engine
A singleton UObject that is responsible for loading and unloading PrimaryAssets, and maintaining game-specific asset references Games should override this class and change the class reference
| Name | UAssetManager |
| Type | class |
| Header File | /Engine/Source/Runtime/Engine/Classes/Engine/AssetManager.h |
| Include Path | #include "Engine/AssetManager.h" |
Syntax
UCLASS (MinimalAPI)
class UAssetManager : public UObject
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UAssetManager
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
UAssetManager() |
Constructor | Engine/AssetManager.h |
Structs
| Name | Remarks |
|---|---|
| FPendingChunkInstall | Defines a set of chunk installs that are waiting |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| AssetSearchRootsVirtualPath | const FString | Virtual path $AssetSearchRoots, replaced with all roots including defaults like /Game | Engine/AssetManager.h |
| DynamicSearchRootsVirtualPath | const FString | Virtual path $DynamicSearchRoots, replaced with dynamically added asset roots | Engine/AssetManager.h |
| MapType | const FPrimaryAssetType | Asset Type of UWorld assets | Engine/AssetManager.h |
| OnAssetManagerCreatedDelegate | FSimpleMulticastDelegate | Delegate called when the asset manager singleton is created | Engine/AssetManager.h |
| OnCompletedInitialScanDelegate | FSimpleMulticastDelegate | Delegate called when initial span finishes | Engine/AssetManager.h |
| PackageChunkType | const FPrimaryAssetType | Type representing a packaging chunk, this is a virtual type that is never loaded off disk | Engine/AssetManager.h |
| PrimaryAssetLabelType | const FPrimaryAssetType | Asset Type of Label used to tag other assets | Engine/AssetManager.h |
| SuppressionType | const FPrimaryAssetType | Asset Type used in return values to indicate that a specific asset of a given PrimaryAssetType should be suppressed and not considered a PrimaryAsset. | Engine/AssetManager.h |
Variables
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| AssetBundlePathsForPackage | TMap< FName, TArray< FTopLevelAssetPath > > | Map from the PackageName of a PrimaryAsset to the packages that should be added to the cook based on the PrimaryAsset's AssetBundleData, if the PrimaryAsset is ever referenced. | Engine/AssetManager.h | |
| AssetTypeMap | TMap< FName, TSharedRef< FPrimaryAssetTypeData > > | Per-type asset information, cannot be accessed by children as it is defined in CPP file | Engine/AssetManager.h | |
| bOldTemporaryCachingMode | bool | Provide proper reentrancy for AssetRegistry temporary caching | Engine/AssetManager.h | |
| bScanningFromInitialConfig | bool | True if we're doing an initial scan, private because this may be replaced by a different data structure | Engine/AssetManager.h | |
| CachedAssetRegistry | IAssetRegistry * | Engine/AssetManager.h | ||
| CachedSettings | const UAssetManagerSettings * | Engine/AssetManager.h | ||
| FCompiledAssetManagerSearchRules | friend | Engine/AssetManager.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AcquireResourcesForAssetList
(
const TArray< FSoftObjectPath >& AssetList, |
Engine/AssetManager.h | ||
virtual void AcquireResourcesForAssetList
(
const TArray< FSoftObjectPath >& AssetList, |
Acquires a set of chunks using the platform chunk layer, then calls the passed in callback | Engine/AssetManager.h | |
virtual void AcquireResourcesForPrimaryAssetList
(
const TArray< FPrimaryAssetId >& PrimaryAssetList, |
Acquires a set of chunks using the platform chunk layer, then calls the passed in callback. | Engine/AssetManager.h | |
virtual void AddAssetSearchRoot
(
const FString& NewRootPath |
Register a new asset search root of the form /AssetRoot, will notify other systems about change | Engine/AssetManager.h | |
virtual bool AddDynamicAsset
(
const FPrimaryAssetId& PrimaryAssetId, |
Adds or updates a Dynamic asset, which is a runtime-specified asset that has no on disk representation, so has no FAssetData. | Engine/AssetManager.h | |
virtual void ApplyCustomPrimaryAssetRulesOverride
(
const FPrimaryAssetRulesCustomOverride& CustomOverride |
Apply a single custom primary asset rule, calls function below | Engine/AssetManager.h | |
virtual void ApplyPrimaryAssetLabels() |
Handles applying Asset Labels and should be overridden to do any game-specific labelling | Engine/AssetManager.h | |
EPrimaryAssetCookRule CalculateCookRuleUnion
(
const TMap< FPrimaryAssetId, UE::AssetRegistry::EDependencyProperty >& Managers, |
Helper function for GetPackageCookRule. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > ChangeBundleStateForMatchingPrimaryAssets
(
const TArray< FName >& NewBundles, |
Changes the bundle state of all loaded primary assets. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > ChangeBundleStateForMatchingPrimaryAssets
(
const TArray< FName >& NewBundles, |
Changes the bundle state of all loaded primary assets. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > ChangeBundleStateForPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToChange, |
Changes the bundle state of a set of loaded primary assets. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > ChangeBundleStateForPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToChange, |
Changes the bundle state of a set of loaded primary assets. | Engine/AssetManager.h | |
virtual FPrimaryAssetId DeterminePrimaryAssetIdForObject
(
const UObject* Object |
If bShouldManagerDetermineTypeAndName is true in settings, this function is used to determine the primary asset id for any object that does not have it's own implementation. | Engine/AssetManager.h | |
virtual bool DoesAssetMatchSearchRules
(
const FAssetData& AssetData, |
Helper function to check if a single asset passes restrictions in SearchRules, this can be used when an asset is manually registered | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > DownloadAssetList
(
TArray< FSoftObjectPath >&& AssetList, |
Rvalue reference overload for Asset List | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > DownloadAssetList
(
const TArray< FSoftObjectPath >& AssetList, |
Download non primary assets with the primary streamable manager. | Engine/AssetManager.h | |
virtual bool ExpandVirtualPaths
(
TArray< FString >& InOutPaths |
Expands a list of paths that potentially use virtual paths into real directory and package paths. | Engine/AssetManager.h | |
virtual FPrimaryAssetId ExtractPrimaryAssetIdFromData
(
const FAssetData& AssetData, |
Parses AssetData to extract the primary type/name from it. | Engine/AssetManager.h | |
virtual void ExtractSoftObjectPaths
(
const UStruct* Struct, |
Extracts all FSoftObjectPaths from a Class/Struct | Engine/AssetManager.h | |
virtual bool FindMissingChunkList
(
const TArray< FSoftObjectPath >& AssetList, |
Returns the list of Chunks that are not currently mounted, and are required to load the referenced assets. | Engine/AssetManager.h | |
virtual void FinishInitialLoading() |
Finishes initial loading, gets called from end of Engine::Init() | Engine/AssetManager.h | |
virtual bool GetAssetBundleEntries
(
const FPrimaryAssetId& BundleScope, |
Appends all AssetBundleInfos inside a given scope | Engine/AssetManager.h | |
virtual FAssetBundleEntry GetAssetBundleEntry
(
const FPrimaryAssetId& BundleScope, |
Returns a single AssetBundleInfo, matching Scope and Name | Engine/AssetManager.h | |
virtual bool GetAssetDataForPath
(
const FSoftObjectPath& ObjectPath, |
Gets the FAssetData at a specific path, handles redirectors and blueprint classes correctly. | Engine/AssetManager.h | |
virtual FSoftObjectPath GetAssetPathForData
(
const FAssetData& AssetData |
Turns an FAssetData into FSoftObjectPath, handles adding _C as necessary | Engine/AssetManager.h | |
IAssetRegistry & GetAssetRegistry() |
Accessor for asset registry | Engine/AssetManager.h | |
const TArray< FString > & GetAssetSearchRoots
(
bool bIncludeDefaultRoots |
Returns all the game asset roots, includes /Game by default and any dynamic ones | Engine/AssetManager.h | |
virtual void GetCachedPrimaryAssetEncryptionKeyGuid
(
FPrimaryAssetId InPrimaryAssetId, |
Get the encryption key guid attached to this primary asset. | Engine/AssetManager.h | |
virtual FGuid GetChunkEncryptionKeyGuid
(
int32 InChunkId |
Retrieve the encryption key guid for a given chunk ID | Engine/AssetManager.h | |
const TMap< int32, FAssetManagerChunkInfo > & GetChunkManagementMap() |
Returns the chunk information map computed during UpdateManagementDatabase | Engine/AssetManager.h | |
virtual void GetContentEncryptionConfig
(
FContentEncryptionConfig& OutContentEncryptionConfig |
Gathers information about which assets the game wishes to encrypt into named groups | Engine/AssetManager.h | |
virtual int32 GetContentEncryptionGroupChunkID
(
FName InGroupName |
For a given content encryption group name (as defined in the content encryption config that the project provides, return the relevant chunk ID | Engine/AssetManager.h | |
virtual TSet< int32 > GetEncryptedChunkIDsForPackage
(
FName InPackageName |
Get the encrypted chunk assignments for a give package. | Engine/AssetManager.h | |
virtual bool GetManagedPackageList
(
FPrimaryAssetId PrimaryAssetId, |
Returns list of asset packages managed by primary asset | Engine/AssetManager.h | |
virtual bool GetPackageChunkIds
(
FName PackageName, |
For a given package and platform, return what Chunks it should be assigned to, games can override this as needed. | Engine/AssetManager.h | |
virtual EPrimaryAssetCookRule GetPackageCookRule
(
FName PackageName |
Returns cook rule for a package name using Management rules, games should override this to take into account their individual workflows | Engine/AssetManager.h | |
virtual bool GetPackageManagers
(
FName PackageName, |
Returns list of PrimaryAssetIds that manage a package. | Engine/AssetManager.h | |
virtual bool GetPackageManagers
(
FName PackageName, |
Returns PrimaryAssetIds that manage a package, with property describing the reference (direct or indirect). | Engine/AssetManager.h | |
virtual void GetPakChunkIdToStringMapping
(
TMap< int32, FString >& ChunkIdStringOverride |
Allows the asset manager to override the chunkID to be a string rather than integer value. | Engine/AssetManager.h | |
void GetPakStringToChunkIdMapping
(
TMap< FString, int32 >& StringOverrideToChunkId |
Helper to make it easy to get the ChunkId based on the string override for a pakchunk. | Engine/AssetManager.h | |
virtual void GetPreviousPrimaryAssetIds
(
const FPrimaryAssetId& NewId, |
Reads redirector list and gets a list of the redirected previous names for a Primary Asset Id | Engine/AssetManager.h | |
void GetPrimaryAssetBundleStateMap
(
TMap< FPrimaryAssetId, TArray< FName > >& BundleStateMap, |
Fills in a TMap with the pending/active loading state of every asset | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetData
(
const FPrimaryAssetId& PrimaryAssetId, |
Gets the FAssetData for a primary asset with the specified type/name, will only work for once that have been scanned for already. | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetDataList
(
FPrimaryAssetType PrimaryAssetType, |
Gets list of all FAssetData for a primary asset type, returns true if any were found | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > GetPrimaryAssetHandle
(
const FPrimaryAssetId& PrimaryAssetId, |
Returns the loading handle associated with the primary asset, it can then be checked for progress or waited on | Engine/AssetManager.h | |
virtual FPrimaryAssetId GetPrimaryAssetIdForData
(
const FAssetData& AssetData |
Returns the primary asset Id for the given FAssetData, only works if in directory | Engine/AssetManager.h | |
virtual FPrimaryAssetId GetPrimaryAssetIdForObject
(
UObject* Object |
Sees if the passed in object is a registered primary asset, if so return it. | Engine/AssetManager.h | |
virtual FPrimaryAssetId GetPrimaryAssetIdForPackage
(
FName PackagePath |
Sees if the package has a primary asset, useful if only the package name is available | Engine/AssetManager.h | |
virtual FPrimaryAssetId GetPrimaryAssetIdForPath
(
const FSoftObjectPath& ObjectPath |
Sees if the passed in object path is a registered primary asset, if so return it. | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetIdList
(
FPrimaryAssetType PrimaryAssetType, |
Gets list of all FPrimaryAssetId for a primary asset type, returns true if any were found | Engine/AssetManager.h | |
bool GetPrimaryAssetLoadList
(
TArray< FSoftObjectPath >& OutAssetLoadList, |
Fills in a array of unique object paths with the assets that need to be loaded, for a given Primary Asset and bundle list | Engine/AssetManager.h | |
bool GetPrimaryAssetLoadSet
(
TSet< FSoftObjectPath >& OutAssetLoadSet, |
Fills in a set of object paths with the assets that need to be loaded, for a given Primary Asset and bundle list. | Engine/AssetManager.h | |
AssetType * GetPrimaryAssetObject
(
const FPrimaryAssetId& PrimaryAssetId |
Templated versions of above | Engine/AssetManager.h | |
virtual UObject * GetPrimaryAssetObject
(
const FPrimaryAssetId& PrimaryAssetId |
Gets the in-memory UObject for a primary asset id, returning nullptr if it's not in memory. | Engine/AssetManager.h | |
TSubclassOf< AssetType > GetPrimaryAssetObjectClass
(
const FPrimaryAssetId& PrimaryAssetId |
Engine/AssetManager.h | ||
virtual bool GetPrimaryAssetObjectList
(
FPrimaryAssetType PrimaryAssetType, |
Gets list of all loaded objects for a primary asset type, returns true if any were found. | Engine/AssetManager.h | |
virtual FSoftObjectPath GetPrimaryAssetPath
(
const FPrimaryAssetId& PrimaryAssetId |
Gets the FSoftObjectPath for a primary asset type and name, returns invalid if not found | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetPathList
(
FPrimaryAssetType PrimaryAssetType, |
Gets the list of all FSoftObjectPaths for a given type, returns true if any found | Engine/AssetManager.h | |
virtual FPrimaryAssetRules GetPrimaryAssetRules
(
FPrimaryAssetId PrimaryAssetId |
Gets the management rules for a specific asset, this will merge the type and individual values | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetSetChunkIds
(
const TSet< FPrimaryAssetId >& PrimaryAssetSet, |
Returns the list of chunks assigned to the list of primary assets, which is usually a manager list. | Engine/AssetManager.h | |
bool GetPrimaryAssetsWithBundleState
(
TArray< FPrimaryAssetId >& PrimaryAssetList, |
Returns a list of primary assets that are in the given bundle state. | Engine/AssetManager.h | |
virtual bool GetPrimaryAssetTypeInfo
(
FPrimaryAssetType PrimaryAssetType, |
Gets metadata for a specific asset type, returns false if not found | Engine/AssetManager.h | |
virtual void GetPrimaryAssetTypeInfoList
(
TArray< FPrimaryAssetTypeInfo >& AssetTypeInfoList |
Gets list of all primary asset types infos | Engine/AssetManager.h | |
virtual FSoftObjectPath GetRedirectedAssetPath
(
const FSoftObjectPath& OldPath |
Reads AssetManagerSettings for specifically redirected asset paths. | Engine/AssetManager.h | |
virtual FPrimaryAssetId GetRedirectedPrimaryAssetId
(
const FPrimaryAssetId& OldId |
Tries to redirect a Primary Asset Id, using list in AssetManagerSettings | Engine/AssetManager.h | |
virtual bool GetResourceAcquireProgress
(
int32& OutAcquiredCount, |
Returns the chunk download/install progress. | Engine/AssetManager.h | |
const UAssetManagerSettings & GetSettings() |
Return settings object | Engine/AssetManager.h | |
| Returns a timer manager that is safe to use for asset loading actions. | Engine/AssetManager.h | ||
virtual FName GetUniqueAssetRegistryName
(
int32 InChunkIndex |
Determine if we should separate the asset registry for this chunk out into its own file and return the unique name that identifies it | Engine/AssetManager.h | |
virtual bool HandleCookCommand
(
FStringView Token |
Processes a command token as part of cooking. | Engine/AssetManager.h | |
virtual bool HasInitialScanCompleted() |
Returns true if initial scan has completed, this can be pretty late in editor builds | Engine/AssetManager.h | |
virtual void InitializeAssetBundlesFromMetadata
(
const UStruct* Struct, |
Initializes asset bundle data from a passed in struct or class, this will read the AssetBundles metadata off the UProperties. | Engine/AssetManager.h | |
virtual void InitializeAssetBundlesFromMetadata
(
const UObject* Object, |
UObject wrapper | Engine/AssetManager.h | |
virtual void InvalidatePrimaryAssetDirectory() |
Invalidate cached asset data so it knows to rescan when needed | Engine/AssetManager.h | |
virtual bool IsAssetDataBlueprintOfClassSet
(
const FAssetData& AssetData, |
Checks to see if the given asset data is a blueprint with a base class in the ClassNameSet. | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > LoadAssetList
(
TArray< FSoftObjectPath >&& AssetList, |
Rvalue reference overload for Asset List | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > LoadAssetList
(
const TArray< FSoftObjectPath >& AssetList, |
Lvalue reference overload to load non primary assets with the primary streamable manager. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadAssetList
(
TArray< FSoftObjectPath >&& AssetList, |
Load non primary assets with the primary streamable manager. | Engine/AssetManager.h | |
TSharedPtr< FStreamableHandle > LoadAssetList
(
const TArray< FSoftObjectPath >& AssetList, |
Load non primary assets with the primary streamable manager. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAsset
(
const FPrimaryAssetId& AssetToLoad, |
Single asset wrapper, see LoadPrimaryAssets | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAsset
(
const FPrimaryAssetId& AssetToLoad, |
Single asset wrapper, see LoadPrimaryAssets | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToLoad, |
Loads a list of Primary Assets. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToLoad, |
Loads a list of Primary Assets. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAssetsWithType
(
FPrimaryAssetType PrimaryAssetType, |
Loads all assets of a given type, useful for cooking | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadPrimaryAssetsWithType
(
FPrimaryAssetType PrimaryAssetType, |
Loads all assets of a given type, useful for cooking | Engine/AssetManager.h | |
virtual void LoadRedirectorMaps() |
Loads the redirector maps | Engine/AssetManager.h | |
| Gets package names to add to the cook, and packages to never cook even if in startup set memory or referenced | Engine/AssetManager.h | ||
virtual void ModifyCookReferences
(
FName PackageName, |
If the given package contains a primary asset, get the packages referenced by its AssetBundleEntries. | Engine/AssetManager.h | |
virtual void ModifyDLCBasePackages
(
const ITargetPlatform* TargetPlatform, |
Allows for game code to modify the base packages that have been read in from the DevelopmentAssetRegistry when performing a DLC cook. | Engine/AssetManager.h | |
| Gets package names to add to a DLC cook | Engine/AssetManager.h | ||
virtual bool OnAssetRegistryAvailableAfterInitialization
(
FName InName, |
Called when a new asset registry becomes available | Engine/AssetManager.h | |
void PopBulkScanning() |
Engine/AssetManager.h | ||
virtual void PostSaveAssetRegistry() |
Called immediately after saving the asset registry during cooking | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > PredownloadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToLoad, |
Downloads data for a set of assets in a specific bundle state, and returns a handle with a FStreamableDownloadCachePin. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > PreloadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToLoad, |
Preloads data for a set of assets in a specific bundle state, and returns a handle you must keep active. | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > PreloadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToLoad, |
Preloads data for a set of assets in a specific bundle state, and returns a handle you must keep active. | Engine/AssetManager.h | |
| Called immediately before saving the asset registry during cooking | Engine/AssetManager.h | ||
void PushBulkScanning () |
Call before many calls to ScanPaths to improve load performance. | Engine/AssetManager.h | |
virtual void RecursivelyExpandBundleData
(
FAssetBundleData& BundleData |
This will expand out references in the passed in AssetBundleData that are pointing to other primary assets with bundles. | Engine/AssetManager.h | |
virtual void RefreshAssetData
(
UObject* ChangedObject |
Refreshes cache of asset data for in memory object | Engine/AssetManager.h | |
virtual void RefreshPrimaryAssetDirectory
(
bool bForceRefresh |
Refresh the entire set of asset data, can call from editor when things have changed dramatically. | Engine/AssetManager.h | |
FDelegateHandle Register_OnAddedAssetSearchRoot
(
FOnAddedAssetSearchRoot::FDelegate&& Delegate |
Call to register a callback executed when a new asset search root is added, can be used to scan for new assets | Engine/AssetManager.h | |
virtual bool RegisterSpecificPrimaryAsset
(
const FPrimaryAssetId& PrimaryAssetId, |
Manually register a new or updated primary asset, returns true if it was successful | Engine/AssetManager.h | |
virtual void ReinitializeFromConfig() |
Resets all asset manager data, called in the editor to reinitialize the config | Engine/AssetManager.h | |
virtual void RemovePrimaryAssetType
(
FPrimaryAssetType PrimaryAssetType |
Engine/AssetManager.h | ||
virtual void RemoveScanPathsForPrimaryAssets
(
FPrimaryAssetType PrimaryAssetType, |
Engine/AssetManager.h | ||
virtual int32 ScanPathForPrimaryAssets
(
FPrimaryAssetType PrimaryAssetType, |
Single path wrapper | Engine/AssetManager.h | |
virtual int32 ScanPathsForPrimaryAssets
(
FPrimaryAssetType PrimaryAssetType, |
Scans a list of paths and reads asset data for all primary assets of a specific type. | Engine/AssetManager.h | |
virtual void ScanPathsSynchronous
(
const TArray< FString >& PathsToScan |
Helper function which requests the asset registery scan a list of directories/assets | Engine/AssetManager.h | |
virtual int32 SearchAssetRegistryPaths
(
TArray< FAssetData >& OutAssetDataList, |
Helper function to search the asset registry for AssetData matching search rules | Engine/AssetManager.h | |
virtual void SetPrimaryAssetRules
(
FPrimaryAssetId PrimaryAssetId, |
Changes the management rules for a specific asset, this overrides the type rules. | Engine/AssetManager.h | |
virtual void SetPrimaryAssetRulesExplicitly
(
FPrimaryAssetId PrimaryAssetId, |
Engine/AssetManager.h | ||
virtual void SetPrimaryAssetTypeRules
(
FPrimaryAssetType PrimaryAssetType, |
Changes the default management rules for a specified type | Engine/AssetManager.h | |
virtual bool ShouldCookForPlatform
(
const UPackage* Package, |
Returns whether or not a specific UPackage should be cooked for the provied TargetPlatform | Engine/AssetManager.h | |
virtual bool ShouldScanPrimaryAssetType
(
FPrimaryAssetTypeInfo& TypeInfo |
Returns true if the specified TypeInfo should be scanned. Can be overridden by the game | Engine/AssetManager.h | |
virtual void StartInitialLoading() |
Starts initial load, gets called from InitializeObjectReferences | Engine/AssetManager.h | |
virtual int32 UnloadPrimaryAsset
(
const FPrimaryAssetId& AssetToUnload |
Single asset wrapper | Engine/AssetManager.h | |
virtual int32 UnloadPrimaryAssets
(
const TArray< FPrimaryAssetId >& AssetsToUnload |
Unloads a list of Primary Assets that were previously Loaded. | Engine/AssetManager.h | |
virtual int32 UnloadPrimaryAssetsWithType
(
FPrimaryAssetType PrimaryAssetType |
Loads all assets of a given type, useful for cooking | Engine/AssetManager.h | |
void Unregister_OnAddedAssetSearchRoot
(
FDelegateHandle DelegateHandle |
Unregister previously added callback | Engine/AssetManager.h | |
void UpdateCachedChunkMapAfterCook
(
const TSet< FName >& AllCookedPackages, |
Called post cook to build the chunk map only with the packages which have been cooked. | Engine/AssetManager.h | |
virtual void UpdateManagementDatabase
(
EUpdateManagementDatabaseFlags InFlags |
Engine/AssetManager.h | ||
virtual void UpdateManagementDatabase
(
bool bForceRefresh |
Updates the asset management database if needed | Engine/AssetManager.h | |
virtual bool VerifyCanCookPackage
(
UE::Cook::ICookInfo* CookInfo, |
Returns true if the specified asset package can be cooked, will error and return false if it is disallowed | Engine/AssetManager.h | |
virtual void WarnAboutInvalidPrimaryAsset
(
const FPrimaryAssetId& PrimaryAssetId, |
Warn about this primary asset id being missing, but only if this is the first time this session | Engine/AssetManager.h | |
virtual bool WriteCustomReport
(
FString FileName, |
Helper function to write out asset reports | Engine/AssetManager.h |
Overridden from UObject
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void BeginDestroy() |
Engine/AssetManager.h | ||
virtual void PostInitProperties() |
Engine/AssetManager.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void AcquireChunkList
(
const TArray< int32 >& ChunkList, |
Call to start acquiring a list of chunks | Engine/AssetManager.h | |
virtual TMap< int32, FAssetManagerChunkInfo > BuildChunkMap
(
const TSet< FName >& PackagesToUpdateChunksFor, |
Used by UpdateManagementDatabase and at the end of the cook to build the CachedChunkMap. | Engine/AssetManager.h | |
virtual TMap< int32, FAssetManagerChunkInfo > BuildChunkMap
(
const TSet< FName >& PackagesToUpdateChunksFor |
Used by UpdateManagementDatabase to build the CachedChunkMap. Should return a new cachedChunkMap. | Engine/AssetManager.h | |
void CallPreGarbageCollect() |
Engine/AssetManager.h | ||
virtual bool DoesPrimaryAssetMatchCustomOverride
(
FPrimaryAssetId PrimaryAssetId, |
Sees if a specific primary asset passes the custom override filter, subclass this to handle FilterString | Engine/AssetManager.h | |
virtual void EndPIE
(
bool bStartSimulate |
Called after PIE ends, resets loading state | Engine/AssetManager.h | |
virtual void GatherPublicAssetsForPackage
(
FName PackagePath, |
Scans the respective PackagePath for public assets to include in AssetsToCook | Engine/AssetManager.h | |
virtual void GatherPublicAssetsForPackage
(
FName PackagePath, |
Scans the respective PackagePath for public assets to include in PackagesToCook | Engine/AssetManager.h | |
virtual void GetAssetDataForPathInternal
(
IAssetRegistry& AssetRegistry, |
Internal helper function that attempts to get asset data from the specified path; Accounts for possibility of blueprint classes ending in _C | Engine/AssetManager.h | |
const FPrimaryAssetData * GetNameData
(
const FPrimaryAssetId& PrimaryAssetId, |
Engine/AssetManager.h | ||
FPrimaryAssetData * GetNameData
(
const FPrimaryAssetId& PrimaryAssetId, |
Returns the NameData for a specific type/name pair | Engine/AssetManager.h | |
bool IsBulkScanning() |
Engine/AssetManager.h | ||
virtual bool IsPathExcludedFromScan
(
const FString& Path |
Returns true if path should be excluded from primary asset scans, called from ShouldIncludeInAssetSearch and in the editor | Engine/AssetManager.h | |
bool IsScanningFromInitialConfig() |
Returns true if we're in the middle of handling the initial config, false if this is being called from something else like a plugin | Engine/AssetManager.h | |
virtual TSharedPtr< FStreamableHandle > LoadAssetListInternal
(
TArray< FSoftObjectPath >&& AssetList, |
Called to load asset list | Engine/AssetManager.h | |
virtual void NotifyOnAssetStateChangeCompleted
(
const FPrimaryAssetId& PrimaryAssetId |
Called when an internal load handle finishes | Engine/AssetManager.h | |
virtual void OnAssetRegistryFilesLoaded() |
Called when asset registry is done loading off disk, will finish any deferred loads | Engine/AssetManager.h | |
virtual void OnAssetRemoved
(
const FAssetData& Data |
When an asset is removed | Engine/AssetManager.h | |
virtual void OnAssetRenamed
(
const FAssetData& NewData, |
When asset is renamed | Engine/AssetManager.h | |
virtual void OnAssetStateChangeCompleted
(
FPrimaryAssetId PrimaryAssetId, |
Called when an internal load handle finishes, handles setting to pending state | Engine/AssetManager.h | |
void OnAssetStateChangeCompleted
(
TSharedPtr< FStreamableHandle > BoundHandle, |
Called when an internal load handle finishes, handles setting to pending state | Engine/AssetManager.h | |
virtual void OnChunkDownloaded
(
uint32 ChunkId, |
Called when a new chunk has been downloaded | Engine/AssetManager.h | |
virtual void OnInMemoryAssetCreated
(
UObject* Object |
Handles updating manager when a new asset is created | Engine/AssetManager.h | |
virtual void OnInMemoryAssetDeleted
(
UObject* Object |
Handles updating manager if deleted object is relevant | Engine/AssetManager.h | |
virtual void OnObjectPreSave
(
UObject* Object, |
Called when object is saved | Engine/AssetManager.h | |
virtual void OnObjectReferenceListInvalidated() |
Engine/AssetManager.h | ||
virtual void PostInitialAssetScan() |
Called after scanning is complete, either from FinishInitialLoading or after the AssetRegistry finishes | Engine/AssetManager.h | |
virtual void PreBeginPIE
(
bool bStartSimulate |
Called right before PIE starts, will refresh asset directory and can be overriden to preload assets | Engine/AssetManager.h | |
virtual void PreGarbageCollect() |
Engine/AssetManager.h | ||
virtual void RemovePrimaryAssetId
(
const FPrimaryAssetId& PrimaryAssetId |
Try to remove an old asset identifier when it has been deleted/renamed | Engine/AssetManager.h | |
virtual void ScanPrimaryAssetRulesFromConfig() |
Called to apply the primary asset rule overrides from config | Engine/AssetManager.h | |
virtual void ScanPrimaryAssetTypesFromConfig() |
Scans all asset types specified in DefaultGame | Engine/AssetManager.h | |
virtual bool ShouldIncludeInAssetSearch
(
const FAssetData& AssetData, |
Filter function that is called from SearchAssetRegistryPaths, returns true if asset data should be included in search results | Engine/AssetManager.h | |
virtual EAssetSetManagerResult::Type ShouldSetManager
(
UE::AssetRegistry::FShouldSetManagerContext& Context |
Function used during creating Management references to decide when to recurse and set references | Engine/AssetManager.h | |
virtual EAssetSetManagerResult::Type ShouldSetManager
(
const FAssetIdentifier& Manager, |
Engine/AssetManager.h | ||
virtual void StartBulkScanning() |
Should only be called from PushBulkScanning() and override | Engine/AssetManager.h | |
virtual void StopBulkScanning() |
Should only be called from PopBulkScanning() and override | Engine/AssetManager.h | |
virtual bool TryUpdateCachedAssetData
(
const FPrimaryAssetId& PrimaryAssetId, |
Updates the asset data cached on the name data; returns false if the asset is not a valid primary asset. | Engine/AssetManager.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static void CallOrRegister_OnAssetManagerCreated
(
FSimpleMulticastDelegate::FDelegate&& Delegate |
Register a delegate to call when the asset manager singleton is spawned, if this has already happened call immediately | Engine/AssetManager.h | |
static void CallOrRegister_OnCompletedInitialScan
(
FSimpleMulticastDelegate::FDelegate&& Delegate |
Register a delegate to call when all types are scanned at startup, if this has already happened call immediately | Engine/AssetManager.h | |
static FPrimaryAssetId CreatePrimaryAssetIdFromChunkId
(
int32 ChunkId |
Creates a PrimaryAssetId from a chunk id | Engine/AssetManager.h | |
static void DumpAssetRegistryInfo() |
Dumps information about the Asset Registry to log | Engine/AssetManager.h | |
static void DumpAssetTypeSummary() |
Dumps out summary of managed types to log | Engine/AssetManager.h | |
static void DumpBundlesForAsset
(
const TArray< FString >& Args |
Shows a list of all bundles for the specified primary asset by primary asset id (i.e. Map:Entry) | Engine/AssetManager.h | |
static void DumpLoadedAssetState() |
Dumps out list of loaded asset bundles to log | Engine/AssetManager.h | |
static void DumpReferencersForPackage
(
const TArray< FString >& PackageNames |
Dumps out list of primary asset -> managed assets to log | Engine/AssetManager.h | |
static int32 ExtractChunkIdFromPrimaryAssetId
(
const FPrimaryAssetId& PrimaryAssetId |
Extracts a chunk id from a primary asset id, returns INDEX_NONE if it is not PackageChunkType | Engine/AssetManager.h | |
static UAssetManager & Get() |
Returns the current AssetManager object | Engine/AssetManager.h | |
static void GetAllReferencersForPackage
(
TSet< FAssetData >& OutFoundAssets, |
Finds all the referencers for a set of packages. | Engine/AssetManager.h | |
static bool GetContentRootPathFromPackageName
(
const FString& PackageName, |
Returns the root path for the package name or path (i.e. /Game/MyPackage would return /Game/ ). | Engine/AssetManager.h | |
static FName GetEncryptionKeyAssetTagName() |
Get the asset registry tag name for encryption key data | Engine/AssetManager.h | |
static UAssetManager * GetIfInitialized() |
Returns the current global singleton AssetManager if it has been constructed, null otherwise | Engine/AssetManager.h | |
static UAssetManager * GetIfValid() |
Engine/AssetManager.h | ||
static FString GetNormalizedPackagePath
(
const FString& InPath, |
Engine/AssetManager.h | ||
static FStreamableManager & GetStreamableManager() |
Accesses the StreamableManager used by this Asset Manager. Static for easy access | Engine/AssetManager.h | |
static bool IsInitialized() |
Returns true if the global singleton AssetManager has been constructed. | Engine/AssetManager.h | |
static bool IsValid() |
Engine/AssetManager.h | ||
static void NormalizePackagePath
(
FString& InOutPath, |
Normalize a package path for use in asset manager, will remove duplicate // and add or remove a final slash as desired | Engine/AssetManager.h |