| | |
| | | /// </summary> |
| | | public static int GameCompletedCount; |
| | | |
| | | /// <summary> |
| | | /// 是否提升过所有塔的等级 |
| | | /// </summary> |
| | | public static bool IsUpgradeTowerLevel; |
| | | |
| | | #region 各个塔的偏移量 |
| | | public static Vector3 fireScale = new Vector3(1.92f, 1.92f, 2.208f); |
| | | public static Vector3 woodScale = new Vector3(1.5f, 1.5f, 2.82f); |
| | |
| | | InitSDK(); |
| | | bGameStart = false; |
| | | bFirstLoaded = false; |
| | | GameConfig.IsUpgradeTowerLevel = false; |
| | | GameConfig.CreateRandomTower = true; |
| | | |
| | | bVibrate = new bool[4]; |
| | |
| | | PlayUpgradeEffect(m_listTower[i]); |
| | | } |
| | | } |
| | | GameConfig.IsUpgradeTowerLevel = true; |
| | | UpdateMinLevelArr(); |
| | | EndlessRandomTower.instance.UpdateDescDisplay(); |
| | | } |
| | |
| | | bool successfulPurchase = EndlessLevelManager.instance.Currency.TryPurchase(cost); |
| | | if (!successfulPurchase) return false; |
| | | |
| | | EndlessRandomTower.instance.UpdateDescDisplay(); |
| | | SetUpGhostTower(tow); |
| | | //Debug.Log("设置影子塔防."); |
| | | m_CurrentTower.Show(); |
| | |
| | | |
| | | public void UpdateDescDisplay() |
| | | { |
| | | int minLevel = Mathf.Min(EndlessGameUI.instance.MinLevel, 1); |
| | | int minLevel = GameConfig.IsUpgradeTowerLevel ? 1 : 0; |
| | | |
| | | NormalDesc.text = $"购买{minLevel + 1}级宝石"; |
| | | } |
| | | |
| | |
| | | gameUI.CancelGhostPlacement(); |
| | | |
| | | if (level == -1) |
| | | level = Mathf.Min(EndlessGameUI.instance.MinLevel, 1); |
| | | { |
| | | level = GameConfig.IsUpgradeTowerLevel ? 1 : 0; |
| | | } |
| | | |
| | | return gameUI.RandomPlaceTower(tower, posx, posy, level, cost, false, isFirstAppear); |
| | | } |