Cylinder.cs 961 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. using UnityEngine;
  2. namespace Rokid.UXR.Interaction {
  3. public class Cylinder : MonoBehaviour
  4. {
  5. [SerializeField]
  6. private float _radius = 1f;
  7. public float Radius
  8. {
  9. get => _radius;
  10. set => _radius = value;
  11. }
  12. [SerializeField]
  13. private float _CylinderCanvasScaleWidth = 1f;
  14. public float CylinderCanvasScaleWidth
  15. {
  16. get => _CylinderCanvasScaleWidth;
  17. set
  18. {
  19. _CylinderCanvasScaleWidth = value;
  20. if (_CylinderCanvasScaleWidth < 1.0f)
  21. {
  22. _CylinderCanvasScaleWidth = 1.0f;
  23. }
  24. }
  25. }
  26. [SerializeField]
  27. private float _CylinderCanvasScaleHeight = 1f;
  28. public float CylinderCanvasScaleHeight
  29. {
  30. get => _CylinderCanvasScaleHeight;
  31. set
  32. {
  33. _CylinderCanvasScaleHeight = value;
  34. if (_CylinderCanvasScaleHeight < 1.0f)
  35. {
  36. _CylinderCanvasScaleHeight = 1.0f;
  37. }
  38. }
  39. }
  40. }
  41. }