/// <summary>
 /// Initialise a new instance of the <see cref="AEntityBufferedSystem{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>
 /// <exception cref="ArgumentNullException"><paramref name="world"/> is null.</exception>
 protected AEntityBufferedSystem(World world)
 {
     _set = EntitySetFactory.Create(GetType())(this, world ?? throw new ArgumentNullException(nameof(world)));
 }
Example #2
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 = EntitySetFactory.Create(GetType())(this, world ?? throw new ArgumentNullException(nameof(world)));
 }