SharedSolarControlConsoleComponent.cs 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. using Robust.Shared.Serialization;
  2. namespace Content.Shared.Solar
  3. {
  4. [Serializable, NetSerializable]
  5. public sealed class SolarControlConsoleBoundInterfaceState : BoundUserInterfaceState
  6. {
  7. /// <summary>
  8. /// The target rotation of the panels in radians.
  9. /// </summary>
  10. public Angle Rotation;
  11. /// <summary>
  12. /// The target velocity of the panels in radians/minute.
  13. /// </summary>
  14. public Angle AngularVelocity;
  15. /// <summary>
  16. /// The total amount of power the panels are supplying.
  17. /// </summary>
  18. public float OutputPower;
  19. /// <summary>
  20. /// The current sun angle.
  21. /// </summary>
  22. public Angle TowardsSun;
  23. public SolarControlConsoleBoundInterfaceState(Angle r, Angle vm, float p, Angle tw)
  24. {
  25. Rotation = r;
  26. AngularVelocity = vm;
  27. OutputPower = p;
  28. TowardsSun = tw;
  29. }
  30. }
  31. [Serializable, NetSerializable]
  32. public sealed class SolarControlConsoleAdjustMessage : BoundUserInterfaceMessage
  33. {
  34. /// <summary>
  35. /// New target rotation of the panels in radians.
  36. /// </summary>
  37. public Angle Rotation;
  38. /// <summary>
  39. /// New target velocity of the panels in radians/second.
  40. /// </summary>
  41. public Angle AngularVelocity;
  42. }
  43. [Serializable, NetSerializable]
  44. public enum SolarControlConsoleUiKey
  45. {
  46. Key
  47. }
  48. }