Exemplo n.º 1
0
 private AEntitiesSystem(IParallelRunner runner, int minEntityCountByRunnerIndex)
 {
 public DefaultEcsComponentSystem(DefaultWorld world, IParallelRunner runner)
     : base(world, runner)
 {
 }
Exemplo n.º 3
0
 /// <summary>
 /// Initialise a new instance of the <see cref="AComponentSystem{TState, TComponent}"/> class with the given <see cref="World"/> and <see cref="IParallelRunner"/>.
 /// </summary>
 /// <param name="world">The <see cref="World"/> on which to process the update.</param>
 /// <param name="runner">The <see cref="IParallelRunner"/> used to process the update in parallel if not null.</param>
 /// <exception cref="ArgumentNullException"><paramref name="world"/> is null.</exception>
 protected AComponentSystem(World world, IParallelRunner runner)
     : this(world, runner, 0)
 {
 }
Exemplo n.º 4
0
 public PositionSystem(World world, IParallelRunner runner)
     : base(world.GetEntities().With <Position>().With <DrawInfo>().AsSet(), runner)
 {
 }
 public DefaultEcsSystem(DefaultWorld world, IParallelRunner runner)
     : base(world.GetEntities().With <DefaultComponent>().AsSet(), runner)
 {
 }
Exemplo n.º 6
0
 public System(World world, IParallelRunner runner, int minEntityCountByRunnerIndex)
     : base(world, runner, minEntityCountByRunnerIndex)
 {
 }
Exemplo n.º 7
0
 public MoveSystem(World world, IParallelRunner runner, Grid grid)
     : base(world, runner)
 {
     _world = world;
     _grid  = grid;
 }
Exemplo n.º 8
0
 /// <summary>
 /// Initialise a new instance of the <see cref="AEntitySystem{T}"/> class with the given <see cref="EntitySet"/> and <see cref="IParallelRunner"/>.
 /// </summary>
 /// <param name="set">The <see cref="EntitySet"/> on which to process the update.</param>
 /// <param name="runner">The <see cref="IParallelRunner"/> used to process the update in parallel if not null.</param>
 /// <param name="minEntityCountByRunnerIndex">The minimum number of <see cref="Entity"/> per runner index to use the given <paramref name="runner"/>.</param>
 /// <exception cref="ArgumentNullException"><paramref name="set"/> is null.</exception>
 protected AEntitySystem(EntitySet set, IParallelRunner runner, int minEntityCountByRunnerIndex)
     : this(runner, minEntityCountByRunnerIndex)
 {
     _set = set ?? throw new ArgumentNullException(nameof(set));
 }
Exemplo n.º 9
0
 /// <summary>
 /// Initialise a new instance of the <see cref="AEntitySystem{T}"/> class with the given <see cref="EntitySet"/> and <see cref="IParallelRunner"/>.
 /// </summary>
 /// <param name="set">The <see cref="EntitySet"/> on which to process the update.</param>
 /// <param name="runner">The <see cref="IParallelRunner"/> used to process the update in parallel if not null.</param>
 /// <exception cref="ArgumentNullException"><paramref name="set"/> is null.</exception>
 protected AEntitySystem(EntitySet set, IParallelRunner runner)
     : this(set, runner, 0)
 {
 }
Exemplo n.º 10
0
 /// <summary>
 /// Initialise a new instance of the <see cref="AEntitySystem{T}"/> class with the given <see cref="World"/>.
 /// To create the inner <see cref="EntitySet"/>, <see cref="WithAttribute"/> and <see cref="WithoutAttribute"/> attributes will be used.
 /// </summary>
 /// <param name="world">The <see cref="World"/> from which to get the <see cref="Entity"/> instances to process the update.</param>
 /// <param name="runner">The <see cref="IParallelRunner"/> used to process the update in parallel if not null.</param>
 /// <exception cref="ArgumentNullException"><paramref name="world"/> is null.</exception>
 protected AEntitySystem(World world, IParallelRunner runner)
     : this(world, runner, 0)
 {
 }
Exemplo n.º 11
0
 private AEntitySystem(IParallelRunner runner, int minEntityCountByRunnerIndex)
 {
     _runner   = runner ?? DefaultParallelRunner.Default;
     _runnable = new Runnable(this);
     _minEntityCountByRunnerIndex = minEntityCountByRunnerIndex;
 }
Exemplo n.º 12
0
 public TestComponentSystem(World world, IParallelRunner runner)
     : base(world, runner)
 {
     _world = world;
 }
Exemplo n.º 13
0
 public TestSystem(World world, IParallelRunner runner)
     : base(world.GetEntities().With <Position>().With <Speed>().AsSet(), runner)
 {
 }
Exemplo n.º 14
0
 public DrawSystem(SpriteBatch batch, World world, IParallelRunner runner) : base(world)
 {
     _batch  = batch;
     _world  = world;
     _runner = runner;
 }
Exemplo n.º 15
0
 public System(EntitySet set, IParallelRunner runner)
     : base(set, runner)
 {
 }
Exemplo n.º 16
0
 /// <summary>
 /// Initialise a new instance of the <see cref="AEntitySystem{T}"/> class with the given <see cref="World"/>.
 /// To create the inner <see cref="EntitySet"/>, <see cref="WithAttribute"/> and <see cref="WithoutAttribute"/> attributes will be used.
 /// </summary>
 /// <param name="world">The <see cref="World"/> from which to get the <see cref="Entity"/> instances to process the update.</param>
 /// <param name="runner">The <see cref="IParallelRunner"/> used to process the update in parallel if not null.</param>
 /// <param name="minEntityCountByRunnerIndex">The minimum number of <see cref="Entity"/> per runner index to use the given <paramref name="runner"/>.</param>
 /// <exception cref="ArgumentNullException"><paramref name="world"/> is null.</exception>
 protected AEntitySystem(World world, IParallelRunner runner, int minEntityCountByRunnerIndex)
     : this(runner, minEntityCountByRunnerIndex)
 {
     _set = EntityRuleBuilderFactory.Create(GetType())(this, world ?? throw new ArgumentNullException(nameof(world))).AsSet();
 }
Exemplo n.º 17
0
 public System(EntitySet set, IParallelRunner runner, int minEntityCountByRunnerIndex)
     : base(set, runner, minEntityCountByRunnerIndex)
 {
 }
Exemplo n.º 18
0
 public ParentSystem(World world, IParallelRunner runner)
     : base(world, runner)
 {
     HierarchyLevelSetter.Setup(world);
 }
Exemplo n.º 19
0
 public DefaultEcsComponentSystem(DefaultWorld world, IParallelRunner runner)
     : base(world.GetEntities().With <DefaultSpeed>().With <DefaultPosition>().AsSet(), runner)
 {
     _world = world;
 }
 public ResetBehaviorSystem(World world, IParallelRunner runner)
     : base(world, runner)
 {
 }
Exemplo n.º 21
0
 public System(World world, IParallelRunner runner)
     : base(world, runner)
 {
 }
Exemplo n.º 22
0
 private AEntityMultiMapSystem(Func <object, EntityMultiMap <TKey> > factory, IParallelRunner runner, int minEntityCountByRunnerIndex)
 {