Assets/Scripts/TowerDefense/UI/HUD/EndlessGameUI.cs
@@ -131,7 +131,7 @@
        /// </summary>
        protected TextMeshProUGUI towerPriceText;
        protected TextMeshProUGUI towerPriceText1;
        //protected TextMeshProUGUI towerPriceText1;
        protected bool tdBuyDisable = false;
@@ -849,6 +849,7 @@
            // 让所有兵线上已经生成的所有agent播放一个死亡动画然后销毁
            WaveLineAgentInsMgr[] waveLineAgentIns = AgentInsManager.instance.GetWaveLineList();
            GameOver();
            for (int i = 0; i < waveLineAgentIns.Length; ++i)
            {
@@ -858,7 +859,6 @@
                }
            }
            GameOver();
            overTimer = new Timer(1.2f, SafelyCallGameOverEvent);
        }
@@ -1363,9 +1363,7 @@
                return false;
            }
            BuyTower(pointer, force, zeroCost);
            return true;
            return BuyTower(pointer, force, zeroCost);
        }
        /// <summary>
@@ -1573,9 +1571,9 @@
        /// Throws exception when not in a build mode or when tower is not a valid position
        /// </exception>
        /// </summary>
        public void BuyTower(UIPointer pointer, bool force = false, bool zeroCost = false)
        public bool BuyTower(UIPointer pointer, bool force = false, bool zeroCost = false)
        {
            if (!isBuilding) return;
            if (!isBuilding) return false;
            // 判断是否格子上重复放置塔防
            if (!m_CurrentTower || !IsGhostAtValidPosition())
@@ -1607,11 +1605,11 @@
                    if (!pointer.raycast.HasValue || pointer.raycast.Value.collider == null)
                    {
                        CancelGhostPlacement();
                        return;
                        return false;
                    }
                    PlaceGhost(pointer);
                }
                return;
                return true;
            }
            // 这是判断是否超出了格子
@@ -1619,7 +1617,7 @@
            if (!pointer.raycast.HasValue || pointer.raycast.Value.collider == null)
            {
                CancelGhostPlacement();
                return;
                return false;
            }
            int cost = m_CurrentTower.controller.purchaseCost;
@@ -1630,6 +1628,8 @@
            {
                PlaceGhost(pointer);
            }
            return true;
        }
        /// <summary>
@@ -1906,16 +1906,16 @@
            if (!towerPriceText)
            {
                towerPriceText = randomTowerBtn.transform.Find("cashText").GetComponent<TextMeshProUGUI>();
                towerPriceText1 = SkillTowerBtn.transform.Find("cashText").GetComponent<TextMeshProUGUI>();
                //towerPriceText1 = SkillTowerBtn.transform.Find("cashText").GetComponent<TextMeshProUGUI>();
                if (towerPriceText)
                    towerPriceText.text = tpMgr.currentTowerPrice.ToString();
                if (towerPriceText1)
                    towerPriceText1.text = tpMgr.currentTowerPrice.ToString();
                // if (towerPriceText1)
                //     towerPriceText1.text = tpMgr.currentTowerPrice.ToString();
            }
            else
            {
                towerPriceText.text = tpMgr.currentTowerPrice.ToString();
                towerPriceText1.text = tpMgr.currentTowerPrice.ToString();
                //towerPriceText1.text = tpMgr.currentTowerPrice.ToString();
            }
            // 无法支付新的塔防价格,按钮变灰.
@@ -1935,7 +1935,7 @@
            if (towerPriceText)
            {
                towerPriceText.color = new Color(0.5f, 0.5f, 0.5f);
                towerPriceText1.color = new Color(0.5f, 0.5f, 0.5f);
                //towerPriceText1.color = new Color(0.5f, 0.5f, 0.5f);
            }
            tdBuyDisable = true;
        }
@@ -1953,7 +1953,7 @@
            if (towerPriceText)
            {
                towerPriceText.color = new Color(1.0f, 1.0f, 1.0f);
                towerPriceText1.color = new Color(1.0f, 1.0f, 1.0f);
                //towerPriceText1.color = new Color(1.0f, 1.0f, 1.0f);
            }
            if (randomTowerBtn)