Mirror of Svelto.ECS because we're a fan of it
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
567B

  1. using Svelto.ECS.Internal;
  2. namespace Svelto.ECS
  3. {
  4. public abstract class SingleEntityViewEngine<T> : IHandleEntityViewEngine where T:EntityView, new()
  5. {
  6. public void Add(IEntityView entityView)
  7. {
  8. Add((T)entityView); //when byref returns will be vailable, this should be passed by reference, not copy!
  9. }
  10. public void Remove(IEntityView entityView)
  11. {
  12. Remove((T)entityView);
  13. }
  14. protected abstract void Add(T entityView);
  15. protected abstract void Remove(T entityView);
  16. }
  17. }