Search Results for

    Show / Hide Table of Contents

    Class SceneManagers

    Manages SceneManager instances and allows the user to access them.

    Inheritance
    object
    SceneManagers
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: Evergine.Framework.Managers
    Assembly: Evergine.Framework.dll
    Syntax
    public class SceneManagers
    Remarks

    Registered SceneManager instances that inherit from UpdatableSceneManager will be updated automatically by this instance. This update order depends on the order in which SceneManager instances where registered (first registered, first to be updated and so on).

    Constructors

    SceneManagers(Scene)

    Initializes a new instance of the SceneManagers class.

    Declaration
    public SceneManagers(Scene scene)
    Parameters
    Type Name Description
    Scene scene

    The Scene.

    Properties

    AssetSceneManager

    Gets the entity manager.

    Declaration
    public AssetSceneManager AssetSceneManager { get; }
    Property Value
    Type Description
    AssetSceneManager

    BehaviorManager

    Gets the behavior manager.

    Declaration
    public BehaviorManager BehaviorManager { get; }
    Property Value
    Type Description
    BehaviorManager

    EntityManager

    Gets the entity manager.

    Declaration
    public EntityManager EntityManager { get; }
    Property Value
    Type Description
    EntityManager

    EnvironmentManager

    Gets the environment manager.

    Declaration
    public EnvironmentManager EnvironmentManager { get; }
    Property Value
    Type Description
    EnvironmentManager

    PhysicManager3D

    Gets the behavior manager.

    Declaration
    public PhysicManager3D PhysicManager3D { get; }
    Property Value
    Type Description
    PhysicManager3D

    RegisteredManagers

    Gets the sceneManagers of the registered sceneManagers.

    Declaration
    public IEnumerable<SceneManager> RegisteredManagers { get; }
    Property Value
    Type Description
    IEnumerable<SceneManager>

    RenderManager

    Gets the render manager.

    Declaration
    public RenderManager RenderManager { get; }
    Property Value
    Type Description
    RenderManager

    Scene

    Gets the associated scene.

    Declaration
    public Scene Scene { get; }
    Property Value
    Type Description
    Scene

    VirtualScreenManager

    Gets the behavior manager.

    Declaration
    public VirtualScreenManager VirtualScreenManager { get; }
    Property Value
    Type Description
    VirtualScreenManager

    Methods

    ActivateManagers()

    Activate scene managers.

    Declaration
    public void ActivateManagers()
    Remarks

    This method initialize only new sceneManagers, not initialized yet.

    AddManager(SceneManager)

    Registers a SceneManager instance.

    Declaration
    public bool AddManager(SceneManager sceneManager)
    Parameters
    Type Name Description
    SceneManager sceneManager

    The instance to register.

    Returns
    Type Description
    bool

    True if the sceneManager has been successfully registered.

    Remarks

    If the instance to register inherits from UpdatableSceneManager this class will handle the update automatically.

    Exceptions
    Type Condition
    ArgumentNullException

    If sceneManager is null.

    ArgumentException

    If sceneManager is disposed or already attached.

    InvalidOperationException

    If a SceneManager with the same type was already registered.

    AddManager<T>(T)

    Registers a SceneManager instance.

    Declaration
    public bool AddManager<T>(T sceneManager) where T : SceneManager
    Parameters
    Type Name Description
    T sceneManager

    The instance to register.

    Returns
    Type Description
    bool

    True if the sceneManager has been successfully registered.

    Type Parameters
    Name Description
    T

    Type of the SceneManager.

    Remarks

    If the instance to register inherits from UpdatableSceneManager this class will handle the update automatically.

    Exceptions
    Type Condition
    ArgumentNullException

    If sceneManager is null.

    ArgumentException

    If sceneManager is disposed or already attached.

    InvalidOperationException

    If a SceneManager with the same type was already registered.

    AttachManagers()

    Activate scene managers.

    Declaration
    public void AttachManagers()
    Remarks

    This method initialize only new sceneManagers, not initialized yet.

    DetachManager(SceneManager)

    Detach the SceneManager instance. Remove from SceneManagers but not destroy it.

    Declaration
    public bool DetachManager(SceneManager sceneManager)
    Parameters
    Type Name Description
    SceneManager sceneManager

    The sceneManager to unregister.

    Returns
    Type Description
    bool

    True if the sceneManager has been successfully unregistered.

    Remarks

    The unregistered SceneManager will be disposed.

    DrawSceneManagers(TimeSpan)

    Updates the registered DrawableSceneManager instances.

    Declaration
    public void DrawSceneManagers(TimeSpan gameTime)
    Parameters
    Type Name Description
    TimeSpan gameTime

    The game time.

    FindManager(Type, bool)

    Gets a SceneManager instance.

    Declaration
    public SceneManager FindManager(Type sceneManagerType, bool isExactType = false)
    Parameters
    Type Name Description
    Type sceneManagerType

    Type of the sceneManager to get.

    bool isExactType

    Whether to match the exact type.

    Returns
    Type Description
    SceneManager

    The SceneManager instance found, or null if there was not a SceneManager with the selected type registered.

    FindManager<T>(bool)

    Gets a SceneManager instance.

    Declaration
    public T FindManager<T>(bool isExactType = false) where T : SceneManager
    Parameters
    Type Name Description
    bool isExactType

    Whether to match the exact type.

    Returns
    Type Description
    T

    The SceneManager instance searched, or null if there was not a SceneManager with the selected type registered.

    Type Parameters
    Name Description
    T

    Type of the SceneManager to get.

    FindManagers(Type, bool)

    Gets a collection of SceneManager instances.

    Declaration
    public IEnumerable<SceneManager> FindManagers(Type sceneManagerType, bool isExactType = false)
    Parameters
    Type Name Description
    Type sceneManagerType

    Type of the sceneManager to get.

    bool isExactType

    Whether to match the exact type.

    Returns
    Type Description
    IEnumerable<SceneManager>

    The SceneManager instance found, or null if there was not a SceneManager with the selected type registered.

    FindManagers<T>(bool)

    Gets a collection of SceneManager instances.

    Declaration
    public IEnumerable<T> FindManagers<T>(bool isExactType = false) where T : SceneManager
    Parameters
    Type Name Description
    bool isExactType

    Whether to match the exact type.

    Returns
    Type Description
    IEnumerable<T>

    The collection of SceneManager instances searched, or null if there was not a SceneManager with the selected type registered.

    Type Parameters
    Name Description
    T

    Type of the SceneManager to get.

    InternalRemoveSceneManager(SceneManager, bool)

    Unregisters a SceneManager.

    Declaration
    public bool InternalRemoveSceneManager(SceneManager sceneManager, bool destroy)
    Parameters
    Type Name Description
    SceneManager sceneManager

    The sceneManager to unregister.

    bool destroy

    True if the sceneManager will be destroyed.

    Returns
    Type Description
    bool

    True if the sceneManager has been successfully unregistered.

    Remarks

    The unregistered SceneManager will be disposed.

    RemoveManager(SceneManager)

    Unregisters a SceneManager.

    Declaration
    public bool RemoveManager(SceneManager sceneManager)
    Parameters
    Type Name Description
    SceneManager sceneManager

    The sceneManager to unregister.

    Returns
    Type Description
    bool

    True if the sceneManager has been successfully unregistered.

    Remarks

    The unregistered SceneManager will be disposed.

    RemoveManager<T>()

    Unregisters a SceneManager.

    Declaration
    public bool RemoveManager<T>() where T : SceneManager
    Returns
    Type Description
    bool

    True if the sceneManager has been successfully unregistered.

    Type Parameters
    Name Description
    T

    Type of the SceneManager to unregister.

    Remarks

    The unregistered SceneManager will be disposed.

    StartManagers()

    Activate scene managers.

    Declaration
    public void StartManagers()
    Remarks

    This method initialize only new sceneManagers, not initialized yet.

    UpdateSceneManagers(TimeSpan)

    Updates the registered UpdatableSceneManager instances.

    Declaration
    public void UpdateSceneManagers(TimeSpan gameTime)
    Parameters
    Type Name Description
    TimeSpan gameTime

    The game time.

    Extension Methods

    ReflectionHelper.GetMemberAssembly(object)
    ReflectionHelper.GetTypeName(object)
    In This Article
    Back to top
    Generated by DocFX