AirControl  1.3.0
Open Source, Modular, and Extensible Flight Simulator For Deep Learning Research
GaugeAxisLine.cs
1 /************************************************/
2 /* */
3 /* Copyright (c) 2018 - 2021 monitor1394 */
4 /* https://github.com/monitor1394 */
5 /* */
6 /************************************************/
7 
8 using System.Collections.Generic;
9 using UnityEngine;
10 
11 namespace XCharts
12 {
13  [System.Serializable]
14  public class StageColor
15  {
16  [SerializeField] private float m_Percent;
17  [SerializeField] private Color32 m_Color;
21  public float percent { get { return m_Percent; } set { m_Percent = value; } }
25  public Color32 color { get { return m_Color; } set { m_Color = value; } }
26 
27  public StageColor(float percent, Color32 color)
28  {
29  m_Percent = percent;
30  m_Color = color;
31  }
32  }
33 
34  [System.Serializable]
35  public class GaugeAxisLine : BaseLine
36  {
37  [SerializeField] private Color32 m_BarColor;
38  [SerializeField] private Color32 m_BarBackgroundColor = new Color32(200, 200, 200, 255);
39  [SerializeField]
40  private List<StageColor> m_StageColor = new List<StageColor>()
41  {
42  new StageColor(0.2f,new Color32(145,199,174,255)),
43  new StageColor(0.8f,new Color32(99,134,158,255)),
44  new StageColor(1.0f,new Color32(194,53,49,255)),
45  };
49  public Color32 barColor { get { return m_BarColor; } set { m_BarColor = value; } }
53  public Color32 barBackgroundColor { get { return m_BarBackgroundColor; } set { m_BarBackgroundColor = value; } }
57  public List<StageColor> stageColor { get { return m_StageColor; } set { m_StageColor = value; } }
58 
59  public GaugeAxisLine(bool show) : base(show)
60  {
61  }
62  }
63 }
XCharts.GaugeAxisLine.stageColor
List< StageColor > stageColor
阶段颜色。
Definition: GaugeAxisLine.cs:57
XCharts.StageColor
Definition: GaugeAxisLine.cs:14
XCharts.GaugeAxisLine
Definition: GaugeAxisLine.cs:35
XCharts.GaugeAxisLine.barBackgroundColor
Color32 barBackgroundColor
进度条背景颜色。
Definition: GaugeAxisLine.cs:53
XCharts
Definition: RewardChart.cs:14
XCharts.StageColor.color
Color32 color
颜色。
Definition: GaugeAxisLine.cs:25
XCharts.StageColor.percent
float percent
结束位置百分比。
Definition: GaugeAxisLine.cs:21
XCharts.GaugeAxisLine.barColor
Color32 barColor
进度条颜色。
Definition: GaugeAxisLine.cs:49
XCharts.BaseLine
Settings related to base line. 线条基础配置。
Definition: BaseLine.cs:17
XCharts.BaseLine.show
bool show
Set this to false to prevent the axis line from showing. 是否显示坐标轴轴线。
Definition: BaseLine.cs:27