Skip to content

Latest commit

 

History

History
58 lines (44 loc) · 9.78 KB

AEntityMultiMapSystem_TState,TKey_.md

File metadata and controls

58 lines (44 loc) · 9.78 KB

AEntityMultiMapSystem<TState,TKey> Class

Represents a base class to process updates on a given EntityMultiMap<TKey> instance.
Only Get<T>() operations on already present component type are safe.
Any other operation maybe change the inner EntityMultiMap<TKey> and should be done either by setting "useBuffer" of the available constructors to true or using an EntityCommandRecorder.

public abstract class AEntityMultiMapSystem<TState,TKey> :
DefaultEcs.System.ISystem<TState>,
System.IDisposable

Type parameters

TState

The type of the object used as state to update the system.

TKey

The type of the component used as key.

Inheritance System.Object 🡒 AEntityMultiMapSystem<TState,TKey>

Implements DefaultEcs.System.ISystem<TState>, System.IDisposable

Constructors
AEntityMultiMapSystem(EntityMultiMap<TKey>, bool) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given EntityMultiMap<TKey>.
AEntityMultiMapSystem(EntityMultiMap<TKey>, IParallelRunner, int) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given EntityMultiMap<TKey> and IParallelRunner.
AEntityMultiMapSystem(World, bool) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used.
AEntityMultiMapSystem(World, IParallelRunner, int) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used.
AEntityMultiMapSystem(World, Func<object,World,EntityMultiMap<TKey>>, bool) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used.
AEntityMultiMapSystem(World, Func<object,World,EntityMultiMap<TKey>>, IParallelRunner, int) Initialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World and factory.
The current instance will be passed as the first parameter of the factory.
Properties
IsEnabled Gets or sets whether the current AEntityMultiMapSystem<TState,TKey> instance should update or not.
MultiMap Gets the EntityMultiMap<TKey> instance on which this system operates.
World Gets the World instance on which this system operates.
Methods
Dispose() Disposes of the inner EntityMultiMap<TKey> instance.
GetKeys() Gets all the TKey of the inner EntityMultiMap<TKey> which Entity instances will be updated.
PostUpdate(TState) Performs a post-update treatment.
PostUpdate(TState, TKey) Performs a post-update per TKey treatment.
PreUpdate(TState) Performs a pre-update treatment.
PreUpdate(TState, TKey) Performs a pre-update per TKey treatment.
Update(TState) Updates the system once.
Does nothing if IsEnabled is false or if the inner EntityMultiMap<TKey> is empty.
Update(TState, TKey, Entity) Update the given Entity instance once.
Update(TState, TKey, ReadOnlySpan<Entity>) Update the given Entity instances once.