using System; using System.Collections.Generic; namespace Syntriax.Engine.Core.Abstract; /// /// Represents a game world responsible for managing s. /// public interface IGameManager : IEntity, IEnumerable { /// /// Event triggered when a is registered to the . /// Action? OnGameObjectRegistered { get; set; } /// /// Event triggered when a is unregistered from the . /// Action? OnGameObjectUnRegistered { get; set; } /// /// Gets a read-only list of s managed by the . /// IReadOnlyList GameObjects { get; } /// /// Registers a to the . /// /// The to register. void RegisterGameObject(IGameObject gameObject); /// /// Instantiates a of type T with the given arguments and registers it to the . /// /// The type of to instantiate. /// Constructor parameters for the given type of . /// The instantiated . T InstantiateGameObject(params object?[]? args) where T : class, IGameObject; /// /// Removes a from the . /// /// The to remove. /// The removed . IGameObject RemoveGameObject(IGameObject gameObject); /// /// Updates the with the given engine time data. /// /// The engine time. void Update(EngineTime time); /// /// Performs operations that should be done before the draw calls. /// void PreDraw(); }