Skip to content

ISystem Interface

Definition

Namespace: Brine2D.ECS

Interface for systems that process entities in the ECS. Systems run before behaviors during EntityWorld.Update().

C#
public interface ISystem

Derived
↳ IRenderSystem
↳ IUpdateSystem
↳ FixedUpdateSystemBase
↳ IFixedUpdateSystem
↳ RenderSystemBase
↳ UpdateSystemBase
↳ ParticleSystem
↳ TilemapSystem

Remarks

Systems are scene-scoped and automatically cleaned up when the scene unloads. Use systems for batch processing of many entities \(physics, collision, etc\.\). For entity-specific logic, use Behavior instead.

Ambient vs. parameter-passed: unlike Behavior (which exposes its framework services as ambient properties since one instance is bound to one entity for its entire attached lifetime), a system instance is shared across many entities and batch-processes all of them on each call. There is no single "current entity" to be ambient about, so systems instead take IEntityWorld (and the entities/components within it) as explicit parameters to Update, FixedUpdate, or Render. See Behavior's remarks for the full rule.

Properties
IsEnabled Whether this system is currently enabled. Disabled systems are skipped during Update().