Search Results for

    Show / Hide Table of Contents

    Class ManagedEditor

    The main managed editor class. Editor root object.

    Inheritance
    Object
    ScriptingObject
    ManagedEditor
    Assembly: FlaxEngine.dll
    File: Editor/Managed/ManagedEditor.h
    Syntax
    public class ManagedEditor : public ScriptingObject

    Constructors

    ~ManagedEditor()

    Finalizes an instance of the ManagedEditor class.

    Declaration
    public ~ManagedEditor()

    ManagedEditor()

    Initializes a new instance of the ManagedEditor class.

    Declaration
    public ManagedEditor()

    Methods

    BeforeRun()

    Declaration
    public void BeforeRun()

    CanAutoBuildCSG()

    Determines whether this managed editor allows auto build CSG mesh on brush modification (based on editor state and settings).

    Declaration
    public bool CanAutoBuildCSG()
    Returns
    bool

    CanAutoBuildNavMesh()

    Determines whether this managed editor allows auto build navigation mesh on scene modification (based on editor state and settings).

    Declaration
    public bool CanAutoBuildNavMesh()
    Returns
    bool

    CanAutoReloadScripts()

    Determines whether this managed editor allows to reload scripts by auto (based on editor options).

    Declaration
    public bool CanAutoReloadScripts() const
    Returns
    bool

    CanReloadScripts()

    Determines whether this managed editor allows reload scripts (based on editor state).

    Declaration
    public bool CanReloadScripts()
    Returns
    bool

    CreateAsset(const String& tag, String outputPath)

    Creates a new asset at the target location.

    Declaration
    public static bool CreateAsset(const String& tag, String outputPath)
    Parameters
    String tag

    New asset type.

    String outputPath

    Output asset path.

    Returns
    bool

    DestroyManaged()

    Declaration
    public virtual void DestroyManaged() override
    Overrides
    ScriptingObject::DestroyManaged()

    EvaluateVisualScriptLocal(VisualScript* script, VisualScriptLocal& local)

    Declaration
    public static bool EvaluateVisualScriptLocal(VisualScript* script, VisualScriptLocal& local)
    Parameters
    VisualScript script

    VisualScriptLocal local

    Returns
    bool

    Exit()

    Exits managed editor.

    Declaration
    public void Exit()

    FocusGameViewport()

    Gives focus to the game viewport (game can receive input).

    Declaration
    public void FocusGameViewport() const

    GameViewportToScreen(const Float2& viewportPos)

    Converts the game viewport position to the screen-space position.

    Declaration
    public Float2 GameViewportToScreen(const Float2& viewportPos) const
    Parameters
    Float2 viewportPos

    The game viewport position.

    Returns
    Float2

    The screen-space position.

    GetAssetReferences(const Guid& assetId)

    Gets a list of asset references of a given asset.

    Declaration
    public static Array<Guid> GetAssetReferences(const Guid& assetId)
    Parameters
    Guid assetId

    The asset ID.

    Returns
    Array<Guid>

    List of referenced assets.

    GetGameWindow(bool forceGet=false)

    Gets the game window used to simulate game in editor. Can be used to capture input for the game scripts.

    Declaration
    public Window* GetGameWindow(bool forceGet=false)
    Parameters
    bool forceGet

    True if always get the window, otherwise only if focused.

    Returns
    Window

    The window or null if hidden.

    GetGameWindowSize()

    Gets the size of the game window output.

    Declaration
    public Float2 GetGameWindowSize()
    Returns
    Float2

    The size.

    GetMainWindow()

    Gets the main window created by the c# editor.

    Declaration
    public Window* GetMainWindow()
    Returns
    Window

    The main window

    GetVisualScriptLocals()

    Declaration
    public static Array<VisualScriptLocal> GetVisualScriptLocals()
    Returns
    Array<VisualScriptLocal>

    GetVisualScriptPreviousScopeFrame()

    Declaration
    public static VisualScriptStackFrame GetVisualScriptPreviousScopeFrame()
    Returns
    VisualScriptStackFrame

    GetVisualScriptStackFrames()

    Declaration
    public static Array<VisualScriptStackFrame> GetVisualScriptStackFrames()
    Returns
    Array<VisualScriptStackFrame>

    HasGameViewportFocus()

    Checks whenever the game viewport is focused by the user (eg. can receive input).

    Declaration
    public bool HasGameViewportFocus() const
    Returns
    bool

    True if game viewport is focused, otherwise false.

    Import(const String& inputPath, const String& outputPath, const AudioTool::Options& options)

    Imports the audio asset file to the target location.

    Declaration
    public static bool Import(const String& inputPath, const String& outputPath, const AudioTool::Options& options)
    Parameters
    String inputPath

    The source file path.

    String outputPath

    The result asset file path.

    AudioTool::Options options

    The import settings.

    Returns
    bool

    True if importing failed, otherwise false.

    Import(const String& inputPath, const String& outputPath, const ModelTool::Options& options)

    Imports the model asset file to the target location.

    Declaration
    public static bool Import(const String& inputPath, const String& outputPath, const ModelTool::Options& options)
    Parameters
    String inputPath

    The source file path.

    String outputPath

    The result asset file path.

    ModelTool::Options options

    The import settings.

    Returns
    bool

    True if importing failed, otherwise false.

    Import(const String& inputPath, const String& outputPath, const TextureTool::Options& options)

    Imports the texture asset file to the target location.

    Declaration
    public static bool Import(const String& inputPath, const String& outputPath, const TextureTool::Options& options)
    Parameters
    String inputPath

    The source file path.

    String outputPath

    The result asset file path.

    TextureTool::Options options

    The import settings.

    Returns
    bool

    True if importing failed, otherwise false.

    Import(String inputPath, String outputPath, void* arg=nullptr)

    Imports the asset file to the target location.

    Declaration
    public static bool Import(String inputPath, String outputPath, void* arg=nullptr)
    Parameters
    String inputPath

    The source file path.

    String outputPath

    The result asset file path.

    void arg

    The custom argument 9native data).

    Returns
    bool

    True if importing failed, otherwise false.

    Init()

    Initializes managed editor.

    Declaration
    public void Init()

    OnAppExit()

    Called when application code calls exit. Editor may end play mode or exit normally.

    Declaration
    public bool OnAppExit()
    Returns
    bool

    True if exit engine, otherwise false.

    RequestStartPlayOnEditMode()

    Requests play mode when the editor is in edit mode ( once ).

    Declaration
    public void RequestStartPlayOnEditMode()

    ScreenToGameViewport(const Float2& screenPos)

    Converts the screen-space position to the game viewport position.

    Declaration
    public Float2 ScreenToGameViewport(const Float2& screenPos) const
    Parameters
    Float2 screenPos

    The screen-space position.

    Returns
    Float2

    The game viewport position.

    TryRestoreImportOptions(AudioTool::Options& options, String assetPath)

    Tries the restore the asset import options from the target resource file.

    Declaration
    public static bool TryRestoreImportOptions(AudioTool::Options& options, String assetPath)
    Parameters
    AudioTool::Options options

    The options.

    String assetPath

    The asset path.

    Returns
    bool

    True settings has been restored, otherwise false.

    TryRestoreImportOptions(ModelTool::Options& options, String assetPath)

    Tries the restore the asset import options from the target resource file.

    Declaration
    public static bool TryRestoreImportOptions(ModelTool::Options& options, String assetPath)
    Parameters
    ModelTool::Options options

    The options.

    String assetPath

    The asset path.

    Returns
    bool

    True settings has been restored, otherwise false.

    TryRestoreImportOptions(TextureTool::Options& options, String assetPath)

    Tries the restore the asset import options from the target resource file.

    Declaration
    public static bool TryRestoreImportOptions(TextureTool::Options& options, String assetPath)
    Parameters
    TextureTool::Options options

    The options.

    String assetPath

    The asset path.

    Returns
    bool

    True settings has been restored, otherwise false.

    Update()

    Updates managed editor.

    Declaration
    public void Update()

    WipeOutLeftoverSceneObjects()

    Declaration
    public static void WipeOutLeftoverSceneObjects()
    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2012-2024 Wojciech Figat