public Aspect Build (World w) { ComponentTypeFactory tf = w.ComponentManager.TypeFactory; Aspect aspect = new Aspect(); this.Associate(tf, allTypes, aspect.AllSet); this.Associate(tf, exclusionTypes, aspect.ExclusionSet); this.Associate(tf, oneTypes, aspect.OneSet); return aspect; }
public List<JSValue> GetEntities(Aspect aspect) { var em = _instance.EntityManager; var lst = em.GetEntities(aspect); List<JSValue> ents = new List<JSValue>(); foreach(var e in lst) { ents.Add(JSValue.Wrap(e)); } return ents; }
public EntitySubscription(World world, AspectPromise builder) { aspect = builder.Build(world); promise = builder; aspectCache = new BitSet(); em = world.EntityManager; activeEntityIds = new BitSet(); entities = new Bag<int>(); listeners = new Bag<ISubscriptionListener>(); insertedIds = new BitSet(); removedIds = new BitSet(); inserted = new Bag<int>(); removed = new Bag<int>(); }
public IntervalEntityProcessingSystem(int interval, Aspect aspect) : base(interval,aspect) { }
public ParallelEntityProcessingSystem(Aspect aspect) : base(aspect) { }
/// <summary> /// Create a new DelayedEntityProcessingSystem. It requires an Aspect /// </summary> /// <param name="aspect"></param> public DelayedEntityProcessingSystem(Aspect aspect) : base(aspect) { }
public EntitySystem(Aspect aspect) { System.Diagnostics.Debug.Assert(aspect != null); this.aspect = aspect; }
public EntitySystem(params Type[] types) { aspect = Aspect.All(types); }
public IntervalEntitySystem(int interval, Aspect aspect) : base(aspect) { this.interval = interval; }
public DelayedEntitySystem(Aspect aspect) : base(aspect) { }