Unit.cs 702 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using PF;
  2. using UnityEngine;
  3. using Quaternion = UnityEngine.Quaternion;
  4. using Vector3 = UnityEngine.Vector3;
  5. namespace ETModel
  6. {
  7. public enum UnitType
  8. {
  9. Hero,
  10. Npc
  11. }
  12. public sealed class Unit: Entity
  13. {
  14. public GameObject GameObject;
  15. public void Awake()
  16. {
  17. }
  18. public Vector3 Position
  19. {
  20. get
  21. {
  22. return GameObject.transform.position;
  23. }
  24. set
  25. {
  26. GameObject.transform.position = value;
  27. }
  28. }
  29. public Quaternion Rotation
  30. {
  31. get
  32. {
  33. return GameObject.transform.rotation;
  34. }
  35. set
  36. {
  37. GameObject.transform.rotation = value;
  38. }
  39. }
  40. public override void Dispose()
  41. {
  42. if (this.IsDisposed)
  43. {
  44. return;
  45. }
  46. base.Dispose();
  47. }
  48. }
  49. }