Represents a base class to process updates on a given World instance to all its components of type TComponent.
public abstract class AComponentSystem<TState,TComponent> :
DefaultEcs.System.ISystem<TState>,
System.IDisposable
TState
The type of the object used as state to update the system.
TComponent
The type of component to update.
Inheritance System.Object 🡒 AComponentSystem<TState,TComponent>
Implements DefaultEcs.System.ISystem<TState>, System.IDisposable
Constructors | |
---|---|
AComponentSystem(World) | Initialise a new instance of the AComponentSystem<TState,TComponent> class with the given World. |
AComponentSystem(World, IParallelRunner) | Initialise a new instance of the AComponentSystem<TState,TComponent> class with the given World and IParallelRunner. |
AComponentSystem(World, IParallelRunner, int) | Initialise a new instance of the AComponentSystem<TState,TComponent> class with the given World and IParallelRunner. |
Properties | |
---|---|
IsEnabled | Gets or sets whether the current AComponentSystem<TState,TComponent> instance should update or not. |
World | Gets the World instance on which this system operates. |
Methods | |
---|---|
Dispose() | Does nothing. |
PostUpdate(TState) | Performs a post-update treatment. |
PreUpdate(TState) | Performs a pre-update treatment. |
Update(TState) | Updates the system once. Does nothing if IsEnabled is false or if there is no component of type TComponent in the World. |
Update(TState, Span<TComponent>) | Update the given TComponent once. |
Update(TState, TComponent) | Update the given TComponent once. |