Browse Source

增加点赞能量爆发效果

大爷 1 year ago
parent
commit
7869c3a037

+ 4 - 3
Unity/Assets/Scripts/Codes/Hotfix/Client/battle/BattleMgr.cs

@@ -345,17 +345,18 @@ namespace ET
                 if (msg.StartsWith("item:"))
                 {
                     EventSystem.Instance.Publish(ShowUIAnimation.Clone(ShowUIAnimation.AniType.Gift, System.Convert.ToInt32(msg[5..])));
-                    return;
                 }
                 else if(msg.StartsWith("bosscome:"))
                 {
                     EventSystem.Instance.Publish(ShowUIAnimation.Clone(ShowUIAnimation.AniType.Monster, System.Convert.ToInt32(msg[9..])));
-                    return;
                 }
                 else if(msg.StartsWith("towerhp"))
                 {
                     EventSystem.Instance.Publish(ShowUIAnimation.Clone(ShowUIAnimation.AniType.Tower, 0));
-                    return;
+                }
+                else if(msg == "like_energy")
+                {
+                    EventSystem.Instance.Publish(ShowUIAnimation.Clone(ShowUIAnimation.AniType.LikeEnergy, 0));
                 }
             });
             /*BubbleTalkEvent

+ 6 - 0
Unity/Assets/Scripts/Codes/Hotfix/Client/battle/BattleMgr_Cmd.cs

@@ -133,6 +133,12 @@ namespace ET
                 case (int)KeyCode.F11:
                     EventSystem.Instance.Publish<SoundMuteEvent>();
                     break;
+                case (int)KeyCode.F12:
+                    session.Call(new C2G_BattleNotify()
+                    {
+                        Message = BattleNotify.TiktokLike_energy.ToString()
+                    }).Coroutine();
+                    break;
             }
             await ETTask.CompletedTask;
         }

+ 1 - 1
Unity/Assets/Scripts/Codes/HotfixView/Client/Effect/BuffEffectMgr.cs

@@ -78,7 +78,7 @@ namespace ET.Client
             //优先判断是否有叠层效果.
             LaunchEffect le = null;
             string key = bt.TemplateID.ToString();
-            string effectName = "";
+            //string effectName = "";
             if (bt.OverlayBindingEffect != null && bt.OverlayBindingEffect.Count > 0)
             {
                 if (buff.BuffExtendData > 0)

+ 7 - 0
Unity/Assets/Scripts/Codes/HotfixView/Client/UI/HUD/CreateHUD.cs

@@ -164,6 +164,13 @@ namespace ET.Client
                     trans = view.GetTransition("t_help");
                     trans.Play();
                     break;
+                case ShowUIAnimation.AniType.LikeEnergy:
+                    trans = view.GetTransition("t_help");
+                    trans.Play();
+                    break;
+                default:
+                    Log.Error($"unknow ui animation: {a.Type}");
+                    break;
             }
 
             await ETTask.CompletedTask;

+ 2 - 1
Unity/Assets/Scripts/Codes/Model/Client/EventTypeClient.cs

@@ -280,7 +280,8 @@ namespace ET
             {
                 Gift,
                 Monster,
-                Tower
+                Tower,
+                LikeEnergy
             }
             public AniType Type;
             public int Param1;