new SystemStore(opts)
- Source:
Centralized place for registering and creating systems.
For internal use only!
Parameters:
Name | Type | Description | ||||||
---|---|---|---|---|---|---|---|---|
opts |
Object |
Properties
|
Members
(private) _factories :Object
- Source:
Object with factories for system types.
Type:
- Object
game :Entropy
- Source:
Game instance injected to constructor.
Type:
Methods
create(type, …args) → {System}
- Source:
Creates new entity instance or acquires one from pool.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
type |
String | type of system to create |
|
args |
Any |
<repeatable> |
arguments passed to |
Returns:
new system ready to be added to engine
- Type
- System
register(descriptor)
- Source:
Registers system.
Parameters:
Name | Type | Description | |||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
descriptor |
Object | object describing system Properties
|
registerMany(descriptiors)
- Source:
Registeres many systems.
Parameters:
Name | Type | Description |
---|---|---|
descriptiors |
Array | array of system's descriptors (see |