From 1b1c4f516fc1d40806f16ef2b5f96b622bcb21fb Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期五, 10 十月 2025 16:18:37 +0800
Subject: [PATCH] 125 战斗 漏提交 同上
---
Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs | 32 ++++++++++++++++++++++++++++++--
1 files changed, 30 insertions(+), 2 deletions(-)
diff --git a/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs b/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
index d02c2b9..563d00f 100644
--- a/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
+++ b/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
@@ -213,12 +213,40 @@
return null;
}
+ // 鏈嶅姟鍣ㄤ慨鏀逛簡 鐜板湪绗竴涓笉涓�瀹氭槸B427 涔熸湁鍙兘鏄疊428 鍏堟斁Buff
+ while (packList.Count > 0)
+ {
+ var pack = packList[0];
+ packList.RemoveAt(0);
+
+ if (pack is HB427_tagSCUseSkill)
+ {
+ packList.Insert(0, pack);
+ break;
+ }
+ else if (pack is CustomHB426CombinePack)
+ {
+ Debug.LogError("鏃犳硶鎵惧埌Skill鍖咃紝鍏堝彂鐜颁簡宓屽鍖�");
+ return null;
+ }
+ else
+ {
+ // Debug.LogError("鍙戠幇闈濻kill鍖咃紝鍏堝垎鍙戞帀: " + pack.GetType().Name);
+ PackageRegedit.Distribute(pack);
+ }
+ }
+
if (startTag.Tag.StartsWith("Skill_"))
{
HB427_tagSCUseSkill skill = packList[0] as HB427_tagSCUseSkill;
- packList.Remove(skill);
- BattleObject _caster = battleField.battleObjMgr.GetBattleObject((int)skill.ObjID);
+ packList.RemoveAt(0);
+ if (null == skill)
+ {
+ Debug.LogError("No HB427_tagSCUseSkill found in packList.");
+ return null;
+ }
+ BattleObject _caster = battleField.battleObjMgr.GetBattleObject((int)skill.ObjID);
// BattleDebug.LogError("_caster == null : " + (_caster == null) + " skill.ObjID : " + skill.ObjID);
SkillRecordAction skillAction = new SkillRecordAction(battleField, _caster, skill, packList);
--
Gitblit v1.8.0