Class ComponentSystemBase
A system provides behavior in an ECS architecture.
Namespace: Unity.Entities
Assembly: Unity.Entities.dll
Syntax
[RequireDerived]
public abstract class ComponentSystemBase
Remarks
System implementations should inherit System
Constructors
Name | Description |
---|---|
Component |
Initializes and returns an instance of a system. |
Properties
Name | Description |
---|---|
Enabled | Controls whether this system executes when its OnUpdate function is called. |
Entity |
The EntityManager object of the World in which this system exists. |
Entity |
The query objects cached by this system. |
Global |
The current change version number in this World. |
Last |
The current version of this system. |
System |
The SystemHandle of this system. |
System |
Obsolete. Use System |
Time | |
World | The World in which this system exists. |
World |
Retrieve world update allocator from system state. |
Methods
Name | Description |
---|---|
Get |
Obsolete. Use Get |
Get |
Manually gets a BufferLookup<T> object that can access a Dynamic |
Get |
Manually gets the run-time type information required to access an array of buffer components in a chunk. |
Get |
Obsolete. Use Get |
Get |
Manually gets a dictionary-like container containing all components of type T, keyed by Entity. |
Get |
Manually gets the run-time type information required to access an array of component data in a chunk. |
Get |
Manually gets the run-time type information required to access an array of component data in a chunk. |
Get |
Manually gets the run-time type information required to access a shared component data in a chunk. |
Get |
Gets the cached query for the specified component types, if one exists; otherwise, creates a new query instance and caches it. |
Get |
Gets the cached query for the specified component types, if one exists; otherwise, creates a new query instance and caches it. |
Get |
Create an entity query from a query description builder. |
Get |
Combines an array of query description objects into a single query. |
Get |
Manually gets an EntityStorageInfoLookup object that can access a Entity |
Get |
Manually gets the run-time type information required to access the array of Entity objects in a chunk. |
Get |
Manually gets the run-time type information required to access a shared component data in a chunk. |
Get |
Gets the value of a singleton buffer component. |
Get |
Gets the Entity instance for a singleton. |
Get |
Gets a reference to the singleton component, for read/write access. |
Get |
Gets the value of a singleton component. |
Get |
Obsolete. Use Get |
Has |
Checks whether a singleton component of the specified type exists. |
On |
Called when this system is created. |
On |
Called when this system is destroyed. |
On |
Called before the first call to OnUpdate and when a system resumes updating after being stopped or disabled. |
On |
Called when this system stops running because no entities match the system's Entity |
Require |
Provide a set of queries, one of which must match entities for the system to run. |
Require |
Provide a set of queries, one of which must match entities for the system to run. |
Require |
Adds a query that must match entities for the system to run. You can add multiple required queries to a system; all of them must match at least one entity for the system to run. |
Require |
Require that a specific component exist for this system to run.
Also includes any components added to a system.
See System |
Require |
Obsolete. Use Require |
Set |
Sets the value of a singleton component. |
Should |
Reports whether this system satisfies the criteria to update. This function is used internally to determine whether the system's OnUpdate function can be skipped. |
Try |
Gets the value of a singleton buffer component, and returns whether or not a singleton buffer component of the specified type exists in the World. |
Try |
Gets the singleton Entity, and returns whether or not a singleton Entity of the specified type exists in the World. |
Try |
Gets the value of a singleton component, and returns whether or not a singleton component of the specified type exists in the World. |
Update() | Executes the system immediately. |