Class EditorLoadingAndSavingUtils
This class is a wrapper for editor loading and saving functionality It is meant to contain only functions that can be executed in script (but are also allowed in C++).
Inherited Members
Namespace: UE4.UnrealEd
Assembly: UE4DotNet.dll
Syntax
public class EditorLoadingAndSavingUtils : UObject
Remarks
It is separated from FEditorFileUtils to ensure new easier to use methods can be created without breaking FEditorFileUtils backwards compatibility However this should be used in place of FEditorFileUtils wherever possible as the goal is to deprecate FEditorFileUtils eventually
Properties
| Improve this Doc View SourceDefaultObject
Get UE4 Default Object for this Class
Declaration
public static EditorLoadingAndSavingUtils DefaultObject { get; }
Property Value
Type | Description |
---|---|
EditorLoadingAndSavingUtils |
StaticClass
Get UE4 Class
Declaration
public static Class StaticClass { get; }
Property Value
Type | Description |
---|---|
Class |
Methods
| Improve this Doc View SourceExportScene(Boolean)
Exports the current scene
Declaration
public static void ExportScene(bool bExportSelectedActorsOnly)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | bExportSelectedActorsOnly |
GetDirtyContentPackages()
Appends array with all currently dirty content packages.
Declaration
public static IReadOnlyCollection<Package> GetDirtyContentPackages()
Returns
Type | Description |
---|---|
System.Collections.Generic.IReadOnlyCollection<Package> |
Remarks
@param OutDirtyPackages Array to append dirty packages to.
GetDirtyMapPackages()
Appends array with all currently dirty map packages.
Declaration
public static IReadOnlyCollection<Package> GetDirtyMapPackages()
Returns
Type | Description |
---|---|
System.Collections.Generic.IReadOnlyCollection<Package> |
Remarks
@param OutDirtyPackages Array to append dirty packages to.
ImportScene(String)
Imports a file such as (FBX or obj) and spawns actors f into the current level
Declaration
public static void ImportScene(string Filename)
Parameters
Type | Name | Description |
---|---|---|
System.String | Filename |
LoadMap(String)
Loads the specified map.
Declaration
public static World LoadMap(string Filename)
Parameters
Type | Name | Description |
---|---|---|
System.String | Filename |
Returns
Type | Description |
---|---|
World |
Remarks
Does not prompt the user to save the current map.
@param Filename Level package filename, including path. @return true if the map was loaded successfully.
LoadMapWithDialog()
Prompts the user to save the current map if necessary, the presents a load dialog and loads a new map if selected by the user.
Declaration
public static World LoadMapWithDialog()
Returns
Type | Description |
---|---|
World |
New(UObject, Name)
Spawn an object of this class
Declaration
public static EditorLoadingAndSavingUtils New(UObject obj = null, Name name = default(Name))
Parameters
Type | Name | Description |
---|---|---|
UObject | obj | |
Name | name |
Returns
Type | Description |
---|---|
EditorLoadingAndSavingUtils |
NewBlankMap(Boolean)
New Blank Map
Declaration
public static World NewBlankMap(bool bSaveExistingMap)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | bSaveExistingMap |
Returns
Type | Description |
---|---|
World |
NewMapFromTemplate(String, Boolean)
New Map from Template
Declaration
public static World NewMapFromTemplate(string PathToTemplateLevel, bool bSaveExistingMap)
Parameters
Type | Name | Description |
---|---|---|
System.String | PathToTemplateLevel | |
System.Boolean | bSaveExistingMap |
Returns
Type | Description |
---|---|
World |
SaveCurrentLevel()
Saves the active level, prompting the use for checkout if necessary.
Declaration
public static bool SaveCurrentLevel()
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
@return true on success, False on fail
SaveDirtyPackages(Boolean, Boolean)
Looks at all currently loaded packages and saves them if their "bDirty" flag is set.
Declaration
public static bool SaveDirtyPackages(bool bSaveMapPackages, bool bSaveContentPackages)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | bSaveMapPackages | |
System.Boolean | bSaveContentPackages |
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
Assume all dirty packages should be saved and check out from source control (if enabled).
@param bSaveMapPackages true if map packages should be saved @param bSaveContentPackages true if we should save content packages. @return true on success, false on fail.
SaveDirtyPackagesWithDialog(Boolean, Boolean)
Looks at all currently loaded packages and saves them if their "bDirty" flag is set.
Declaration
public static bool SaveDirtyPackagesWithDialog(bool bSaveMapPackages, bool bSaveContentPackages)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | bSaveMapPackages | |
System.Boolean | bSaveContentPackages |
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
Prompt the user to select which dirty packages to save and check them out from source control (if enabled).
@param bSaveMapPackages true if map packages should be saved @param bSaveContentPackages true if we should save content packages. @return true on success, false on fail.
SaveMap(World, String)
Saves the specified map, returning true on success.
Declaration
public static bool SaveMap(World World, string AssetPath)
Parameters
Type | Name | Description |
---|---|---|
World | World | |
System.String | AssetPath |
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
@param World The world to save. @param AssetPath The valid content directory path and name for the asset. E.g "/Game/MyMap"
@return true if the map was saved successfully.
SavePackages(Byte, Boolean)
Save all packages.
Declaration
public static bool SavePackages(byte PackagesToSave, bool bOnlyDirty)
Parameters
Type | Name | Description |
---|---|---|
System.Byte | PackagesToSave | |
System.Boolean | bOnlyDirty |
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
Assume all dirty packages should be saved and check out from source control (if enabled).
@param PackagesToSave The list of packages to save. Both map and content packages are supported @param bCheckDirty If true, only packages that are dirty in PackagesToSave will be saved @return true on success, false on fail.
SavePackagesWithDialog(Byte, Boolean)
Save all packages.
Declaration
public static bool SavePackagesWithDialog(byte PackagesToSave, bool bOnlyDirty)
Parameters
Type | Name | Description |
---|---|---|
System.Byte | PackagesToSave | |
System.Boolean | bOnlyDirty |
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
Optionally prompting the user to select which packages to save. Prompt the user to select which dirty packages to save and check them out from source control (if enabled).
@param PackagesToSave The list of packages to save. Both map and content packages are supported @param bCheckDirty If true, only packages that are dirty in PackagesToSave will be saved @return true on success, false on fail.
UnloadPackages(Byte)
Unloads a list of packages @
Declaration
public static (bool, byte) UnloadPackages(byte PackagesToUnload)
Parameters
Type | Name | Description |
---|---|---|
System.Byte | PackagesToUnload |
Returns
Type | Description |
---|---|
System.ValueTuple<System.Boolean, System.Byte> |
Remarks
param PackagesToUnload Array of packages to unload.
Operators
| Improve this Doc View SourceImplicit(IntPtr to EditorLoadingAndSavingUtils)
Convert from IntPtr to UObject
Declaration
public static implicit operator EditorLoadingAndSavingUtils(IntPtr p)
Parameters
Type | Name | Description |
---|---|---|
System.IntPtr | p |
Returns
Type | Description |
---|---|
EditorLoadingAndSavingUtils |