SceneNode
Represents a scene within a SceneGraph and manages its dependencies.
Definition
Namespace: Paragon.Core.SceneManagement
Assembly: Paragon.dll
[Serializable]
public class SceneNodeProperties
Scene
The scene this node represents.
public Scene Scene { get; }Constructors
SceneNode(SceneGraph, Scene)
Creates a new scene node.
public SceneNode(SceneGraph graph, Scene scene);graph
SceneGraph
The parent graph
scene
Scene
The scene this node represents
Methods
AddDependency()
Adds a scene as a dependency.
scene
Scene
The dependency to add
Logs an error if the scene doesn't exist in the graph or is already a dependency.
RemoveDependency()
Removes a dependency from this node.
node
SceneNode
The dependency node to remove
HasDependency()
Checks if a scene is a direct dependency.
scene
Scene
The scene to check
Returns: bool — true if it's a dependency
GetDependencies()
Returns all direct dependencies of this node.
Returns: IEnumerable<Scene> — The dependency scenes
ToString()
Returns the scene name.
Returns: string — The scene name
Remarks
Dependencies are resolved recursively by SceneManager when loading scenes. If scene A depends on scene B, and B depends on C, loading A with loadDependencies = true will load C first, then B, then A.
See Also
Last updated
Was this helpful?