EasyEcs
API reference

World.DescendantWalk

A depth-first walk of World.Descendants: a stack of the child lists still being read, given back to the world by World.DescendantWalk.Dispose…

public ref struct DescendantWalk

Nested in World.

A depth-first walk of World.Descendants: a stack of the child lists still being read, given back to the world by World.DescendantWalk.Dispose (foreach calls it).

Properties

Current

public readonly Entity Current { get; }

The current descendant.

Methods

Dispose

public void Dispose();

Give the stack back to the world for the next walk.

MoveNext

public bool MoveNext();

Move to the next descendant. O(1) per entity, plus one step per list it finishes.

Exceptions

  • InvalidOperationException: The ChildOf links form a cycle.
Edit on GitHub

Last updated on

How is this guide?

On this page