ValueIndex<T, TKey>.Ordered
Enumerates entities in key order (foreach): every entity of a key, then the next key.
public ref struct OrderedNested in ValueIndex.
Enumerates entities in key order (foreach): every entity of a key, then the next key. O(log keys) to start, O(1) per entity and per key. Destroying entities during the loop is allowed, changing T is not.
Properties
Current
public readonly Entity Current { get; }The current entity.
Key
public readonly TKey Key { get; }The key of ValueIndex.Ordered.Current.
Methods
GetEnumerator
public readonly ValueIndex<T, TKey>.Ordered GetEnumerator();The enumerator itself (foreach support, no allocation).
MoveNext
public bool MoveNext();Move to the next entity, in key order.
Last updated on
How is this guide?
ValueIndex<T, TKey>.Matches
Enumerates the entities of one key (foreach). The ValueIndex<T, TKey>.Matches struct of EasyEcs, the C# ECS: its members, parameters and complexity.
WithAnyAttribute<T>
The ForEachAttribute method requires at least one of the components named by its [WithAny<T>] attributes (not passed in)…