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.

24 lines
605B

  1. #if UNITY_5 || UNITY_5_3_OR_NEWER
  2. using UnityEngine;
  3. namespace Svelto.ECS.Unity
  4. {
  5. public abstract class GenericEntityDescriptorHolder<T>:
  6. MonoBehaviour , IEntityDescriptorHolder
  7. where T: IEntityDescriptor, new()
  8. {
  9. public IEntityDescriptor GetDescriptor()
  10. {
  11. return EntityDescriptorTemplate<T>.descriptor;
  12. }
  13. public string groupName => _groupName;
  14. public ushort id => _id;
  15. #pragma warning disable 649
  16. [SerializeField] string _groupName;
  17. [SerializeField] ushort _id;
  18. #pragma warning restore 649
  19. }
  20. }
  21. #endif