From 1f5eda1c9d22a3676298751c7282a5874f13bed0 Mon Sep 17 00:00:00 2001
From: River Jiang <546213258@qq.com>
Date: Tue, 27 Oct 2020 17:26:52 +0800
Subject: [PATCH] 加入充能、子弹进度条保持进度的功能

---
 Assets/Scripts/TowerDefense/UI/EnergyUICtl.cs |   20 ++++++++++++++++++++
 1 files changed, 20 insertions(+), 0 deletions(-)

diff --git a/Assets/Scripts/TowerDefense/UI/EnergyUICtl.cs b/Assets/Scripts/TowerDefense/UI/EnergyUICtl.cs
index f8a25c7..1cff95b 100644
--- a/Assets/Scripts/TowerDefense/UI/EnergyUICtl.cs
+++ b/Assets/Scripts/TowerDefense/UI/EnergyUICtl.cs
@@ -24,6 +24,26 @@
     }
 
     /// <summary>
+    /// 获取进度条进度.
+    /// </summary>
+    /// <returns></returns>
+    public int GetCtlProgress()
+    {
+        return currentProgress;
+    }
+
+    /// <summary>
+    /// 设置进度.
+    /// </summary>
+    /// <param name="pro"></param>
+    public void SetCtlProcess(int pro)
+    {
+        if (pro == 10)
+            pro = 0;
+        this.SetEnergyProgress(pro);
+    }
+
+    /// <summary>
     /// 显示并更新能量条进度.
     /// </summary>
     /// <param name="pro"></param>

--
Gitblit v1.9.1