From 39001a600fcae2bcf27c225df8752d75fb92fef4 Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期五, 31 十月 2025 11:18:26 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.1.20:10010/r/Project_SG_scripts
---
Main/System/Battle/BattleManager.cs | 38 +++++++++++++++++++++++++++++++++++---
1 files changed, 35 insertions(+), 3 deletions(-)
diff --git a/Main/System/Battle/BattleManager.cs b/Main/System/Battle/BattleManager.cs
index 699bbee..f879dec 100644
--- a/Main/System/Battle/BattleManager.cs
+++ b/Main/System/Battle/BattleManager.cs
@@ -23,7 +23,9 @@
QuickSetting.Instance.SendPackage();
}
}
-
+ public readonly int[] speedIndexfuncIdArr = new int[] { 34, 35, 36 }; // 鎴樻枟鍊嶆暟瀵瑰簲鐨勫姛鑳絀D
+ public readonly int passFuncId = 33; // 璺宠繃鎴樻枟瀵瑰簲鐨勫姛鑳絀D
+ public int passRound; // 瓒呰繃X鍥炲悎鍙烦杩�
public int fightGuideID;
public int fightGuideMainLevelLimit;
public int fightGuideNoClickSeconds;
@@ -54,6 +56,9 @@
fightGuideID = int.Parse(config.Numerical1);
fightGuideMainLevelLimit = int.Parse(config.Numerical2);
fightGuideNoClickSeconds = int.Parse(config.Numerical3);
+
+ config = FuncConfigConfig.Get("BattleButton");
+ passRound= int.Parse(config.Numerical1);
}
@@ -67,8 +72,8 @@
protected void OnPlayerLoginOk()
{
- long exAttr1 = PlayerDatas.Instance.GetPlayerDataByType(PlayerDataType.ExAttr1);
- long exAttr2 = PlayerDatas.Instance.GetPlayerDataByType(PlayerDataType.ExAttr2);
+ long exAttr1 = PlayerDatas.Instance.baseData.ExAttr1;
+ long exAttr2 = PlayerDatas.Instance.baseData.ExAttr2;
int MapID = 1;
int FuncLineID = (int)exAttr2;
@@ -586,6 +591,33 @@
return null;
}
+ //鍙戣繘鍏ユ垬鏂楀寘
+ private float lastTime = 0f;
+ private float turnCoolDown = 0.5f; // 鍐峰嵈鏃堕棿
+ public void SendTurnFight(uint mapID, uint funcLineID = 0, byte tagType = 0, uint tagID = 0, uint[] valueList = null)
+ {
+ // 杩炵画棰戠箒鍙戝寘锛岃Е鍙戞彁绀�
+ float currentTime = Time.time;
+ if (currentTime - lastTime < turnCoolDown)
+ {
+ SysNotifyMgr.Instance.ShowTip("BattleCoolDown");
+ return;
+ }
+ lastTime = currentTime;
+
+ CB410_tagCMTurnFight pack = new CB410_tagCMTurnFight();
+ pack.MapID = mapID;
+ pack.FuncLineID = funcLineID;
+ pack.TagType = tagType;
+ pack.TagID = tagID;
+ if (!valueList.IsNullOrEmpty())
+ {
+ pack.ValueList = valueList;
+ pack.ValueCount = (byte)valueList.Length;
+ }
+ GameNetSystem.Instance.SendInfo(pack);
+ }
+
// 鑾峰彇褰撳墠姝e湪鏄剧ず鐨勬垬鏂楀満鏅悕绉帮紝濡傛灉娌℃湁鍒欒繑鍥炵┖瀛楃涓�
public string GetActiveBattleName()
{
--
Gitblit v1.8.0