-added mixin for adding exluded components using it's type -demos: *added GUI for selecting templates and choosing tools *change SpaceInvades SideMove system to not using events for better performance and multithreading *added Entites spawning support *fixed some Snake demo bugs *GUI work's better now
29 lines
No EOL
445 B
D
29 lines
No EOL
445 B
D
module ecs.core;
|
|
|
|
public import ecs.manager;
|
|
public import ecs.entity;
|
|
|
|
static struct ECS
|
|
{
|
|
mixin template System(uint jobs_count = 32)
|
|
{
|
|
__gshared ushort system_id;
|
|
uint __ecs_jobs_count = jobs_count;
|
|
}
|
|
|
|
mixin template Component()
|
|
{
|
|
__gshared ushort component_id;
|
|
}
|
|
|
|
mixin template Event()
|
|
{
|
|
__gshared ushort event_id;
|
|
EntityID entity_id;
|
|
}
|
|
|
|
mixin template ExcludedComponents(T...)
|
|
{
|
|
alias ExcludedComponents = T;
|
|
}
|
|
} |