From 682849c0a0949bc4dd1335d0d0fdb80926cc324c Mon Sep 17 00:00:00 2001 From: yangjing Date: Wed, 8 Jun 2022 21:56:34 +0800 Subject: [PATCH] =?UTF-8?q?=E6=92=AD=E6=8F=92=E5=B1=8F=E4=BD=8D=E7=BD=AE?= =?UTF-8?q?=E6=94=B9=E5=9B=9E=E5=8E=9F=E6=9D=A5=E7=9A=84=EF=BC=8C=E8=A1=A5?= =?UTF-8?q?=E5=85=85=E6=9C=AA=E5=90=8C=E6=AD=A5=E7=9A=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Assets/Resources/UI/Panel/PanelGame.prefab | 4 ++-- Assets/Resources/UI/Panel/PanelGuide.prefab | 16 ++++++++-------- Assets/Scenes/Game.unity | 2 +- .../Game/Wars/GroupManager/EnemyManager.cs | 4 ++-- Assets/Scripts/Logic/GameLogic.cs | 2 ++ Assets/Scripts/UIs/PanelResult.cs | 4 ++-- 6 files changed, 17 insertions(+), 15 deletions(-) diff --git a/Assets/Resources/UI/Panel/PanelGame.prefab b/Assets/Resources/UI/Panel/PanelGame.prefab index b894fe04..7623b830 100644 --- a/Assets/Resources/UI/Panel/PanelGame.prefab +++ b/Assets/Resources/UI/Panel/PanelGame.prefab @@ -183,7 +183,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 0, y: 220} + m_AnchoredPosition: {x: 0, y: 360} m_SizeDelta: {x: 192, y: 192} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &3202746937996263206 @@ -820,7 +820,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 0, y: 220} + m_AnchoredPosition: {x: 0, y: 360} m_SizeDelta: {x: 481, y: 244} m_Pivot: {x: 0.5, y: 0.5} --- !u!222 &3202746939300847411 diff --git a/Assets/Resources/UI/Panel/PanelGuide.prefab b/Assets/Resources/UI/Panel/PanelGuide.prefab index 0b50a466..0c54ab38 100644 --- a/Assets/Resources/UI/Panel/PanelGuide.prefab +++ b/Assets/Resources/UI/Panel/PanelGuide.prefab @@ -706,7 +706,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 90} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 170, y: -120} + m_AnchoredPosition: {x: 170, y: 30} m_SizeDelta: {x: 200, y: 200} m_Pivot: {x: 0.5, y: 0.55} --- !u!222 &7877568658873081054 @@ -834,7 +834,7 @@ MonoBehaviour: autoPlay: 0 useTargetAsV3: 0 endValueFloat: 0 - endValueV3: {x: 0, y: -120, z: 0} + endValueV3: {x: 0, y: 30, z: 0} endValueV2: {x: 0, y: 0} endValueColor: {r: 1, g: 1, b: 1, a: 1} endValueString: @@ -922,7 +922,7 @@ RectTransform: m_LocalEulerAnglesHint: {x: 0, y: 0, z: 90} m_AnchorMin: {x: 0.5, y: 0.5} m_AnchorMax: {x: 0.5, y: 0.5} - m_AnchoredPosition: {x: 30, y: -430} + m_AnchoredPosition: {x: 30, y: -280} m_SizeDelta: {x: 200, y: 200} m_Pivot: {x: 0.5, y: 0.55} --- !u!222 &7877568659269773446 @@ -1050,7 +1050,7 @@ MonoBehaviour: autoPlay: 0 useTargetAsV3: 0 endValueFloat: 0 - endValueV3: {x: 30, y: -120, z: 0} + endValueV3: {x: 30, y: 30, z: 0} endValueV2: {x: 0, y: 0} endValueColor: {r: 1, g: 1, b: 1, a: 1} endValueString: @@ -1401,7 +1401,7 @@ PrefabInstance: - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} propertyPath: m_AnchoredPosition.y - value: 450 + value: 600 objectReference: {fileID: 0} - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} @@ -1558,7 +1558,7 @@ PrefabInstance: - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} propertyPath: m_AnchoredPosition.y - value: 200 + value: 365 objectReference: {fileID: 0} - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} @@ -1700,7 +1700,7 @@ PrefabInstance: - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} propertyPath: m_AnchoredPosition.y - value: 200 + value: 365 objectReference: {fileID: 0} - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} @@ -1842,7 +1842,7 @@ PrefabInstance: - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} propertyPath: m_AnchoredPosition.y - value: 450 + value: 600 objectReference: {fileID: 0} - target: {fileID: 1304971611175877922, guid: d8dbcb675f62744a4b0d67e0735ff227, type: 3} diff --git a/Assets/Scenes/Game.unity b/Assets/Scenes/Game.unity index 8ed604d2..e79e9760 100644 --- a/Assets/Scenes/Game.unity +++ b/Assets/Scenes/Game.unity @@ -629,7 +629,7 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 230701045} m_LocalRotation: {x: 0, y: 1, z: 0, w: 0} - m_LocalPosition: {x: 0, y: 0, z: 6.5} + m_LocalPosition: {x: 0, y: 0, z: 15} m_LocalScale: {x: 1, y: 1, z: 1} m_Children: - {fileID: 1617442649} diff --git a/Assets/Scripts/Game/Wars/GroupManager/EnemyManager.cs b/Assets/Scripts/Game/Wars/GroupManager/EnemyManager.cs index 6de72fbe..6ccdf667 100644 --- a/Assets/Scripts/Game/Wars/GroupManager/EnemyManager.cs +++ b/Assets/Scripts/Game/Wars/GroupManager/EnemyManager.cs @@ -13,8 +13,8 @@ public class EnemyManager : GroupManager if (PlayerData.Instance.CurrentLevel <= 3) { - tAttr.MaxHP = (int)(0.8f * tAttr.MaxHP); - tAttr.Damage = (int)(0.8f * tAttr.Damage); + tAttr.MaxHP = (int)(0.75f * tAttr.MaxHP); + tAttr.Damage = (int)(0.75f * tAttr.Damage); } pUnit.InitAttr(tAttr); diff --git a/Assets/Scripts/Logic/GameLogic.cs b/Assets/Scripts/Logic/GameLogic.cs index 88bfca36..cf8e1402 100644 --- a/Assets/Scripts/Logic/GameLogic.cs +++ b/Assets/Scripts/Logic/GameLogic.cs @@ -302,6 +302,8 @@ public class GameLogic : MonoBehaviour mOverTimer.StartTimer(() => { + AdsUtils.PlayInterstitial(mIsWin ? Const.AdsValue.GameSuccess : Const.AdsValue.GameFailure, mIsWin); + PanelResult tUIResult = UIManager.Instance.OpenUI(); tUIResult.InitResult(mIsWin, mEnemyGroupMgr.TotalDamage, TKGSDKManager.Instance.GetConfigBool(TKGParamKey.NativeSwitch.ToString()) && TKGUtils.IsNativeReady()); diff --git a/Assets/Scripts/UIs/PanelResult.cs b/Assets/Scripts/UIs/PanelResult.cs index e4836cd5..7c7cf47a 100644 --- a/Assets/Scripts/UIs/PanelResult.cs +++ b/Assets/Scripts/UIs/PanelResult.cs @@ -60,7 +60,7 @@ public class PanelResult : BasePanel else { float tLevelFactor = ((PlayerData.Instance.CurrentLevel - 1) / 20) * 0.5f + 1; - mBaseCoin = (int)(pTotalHurt * 10 * tLevelFactor * (mWin ? 1 : 0.5f)); + mBaseCoin = (int)(pTotalHurt * 10 * tLevelFactor * (mWin ? 1f : 0.3f)); } mIsRolling = true; @@ -198,7 +198,7 @@ public class PanelResult : BasePanel mBtnAdCoin.gameObject.SetActive(false); mBtnContinue.gameObject.SetActive(false); - TimerManager.Instance.Schedule(LoadGame, pWaitSeconds); + TimerManager.Instance.Schedule(GameManager.Instance.LoadGame, pWaitSeconds); } private void LoadGame()