From 3bc28c54e82721b7858eaa3507f0f65a4041736d Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期五, 08 八月 2025 18:51:39 +0800
Subject: [PATCH] 125 【战斗】战斗系统 协议更新 配置更新
---
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs.meta | 2
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs.meta | 2
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs.meta | 2
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs | 33 ++
Main/System/Battle/BattleField/StoryBattleField.cs | 8
Main/System/Battle/SkillEffect/SkillEffectFactory.cs | 2
Main/System/Battle/BattleObject/BattleObject.cs | 4
Main/System/Battle/Skill/DirectlyHealSkill.cs | 6
Main/System/Battle/SkillEffect/BulletCurve/PenetrateBulletCurve.cs | 2
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs.meta | 2
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs | 11
Main/System/Battle/Skill/SkillFactory.cs | 4
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs | 11
Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs | 29 +
Main/System/Battle/SkillEffect/BulletSkillEffect.cs | 10
Main/System/Battle/Skill/SkillBase.cs | 61 +++
Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0407_tagNPCDisappear.cs | 4
Main/System/Battle/BattleField/RecordActions/SkillRecordAction.cs | 2
Main/System/Battle/SkillEffect/NormalSkillEffect.cs | 10
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs | 21 +
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs.meta | 2
Main/System/Battle/BattleObject/BattleObjectFactory.cs | 29 ++
Main/System/Battle/SkillEffect/BulletCurve/BounceBulletCurve.cs | 6
Main/System/Battle/SkillEffect/BulletCurve/StraightBulletCurve.cs | 2
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs | 53 ++++
Main/System/Battle/Buff/BattleObjectBuffMgr.cs | 5
Main/System/Battle/SkillEffect/BulletCurve/BulletCurveFactory.cs | 4
Main/Config/Configs/NPCConfig.cs | 192 -------------
Main/System/Battle/BattleField/BattleField.cs | 19 +
Main/System/Battle/BattleTweenMgr.cs | 12
Main/System/Battle/Buff/BuffFactory.cs | 2
Main/System/Message/RichTableEvent.cs | 2
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs | 11
Main/System/Battle/SkillEffect/BulletCurve/BezierBulletCurve.cs | 2
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs | 11
Main/System/Battle/BattleEffectMgr.cs | 16 +
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs | 29 ++
Main/System/Battle/SkillEffect/BulletCurve/BulletCurve.cs | 4
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs.meta | 2
Main/System/Battle/BattleManager.cs | 21 +
Main/System/Battle/Skill/DirectlyDamageSkill.cs | 6
Main/System/Battle/Skill/RebornSkill.cs | 6
Main/System/Battle/SkillEffect/SkillEffect.cs | 6
Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs.meta | 2
/dev/null | 11
Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs.meta | 2
Main/System/Battle/Buff/BuffBase.cs | 6
Main/System/Battle/RecordPlayer/RecordPlayer.cs | 10
Main/Core/NetworkPackage/DataToCtl/PackageRegedit.cs | 8
Main/System/Battle/BattleObject/BattleObjMgr.cs | 6
Main/System/Team/TeamHero.cs | 31 +
Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0418_tagObjInfoRefresh.cs | 4
Main/System/Battle/BattleField/OperationAgent/HandModeOperationAgent.cs | 26 +
Main/System/HeroUI/HeroUIManager.cs | 2
54 files changed, 485 insertions(+), 291 deletions(-)
diff --git a/Main/Config/Configs/NPCConfig.cs b/Main/Config/Configs/NPCConfig.cs
index 5b8a62b..003c236 100644
--- a/Main/Config/Configs/NPCConfig.cs
+++ b/Main/Config/Configs/NPCConfig.cs
@@ -1,6 +1,6 @@
锘�//--------------------------------------------------------
// [Author]: YYL
-// [ Date ]: 2025骞�8鏈�5鏃�
+// [ Date ]: 2025骞�8鏈�8鏃�
//--------------------------------------------------------
using System.Collections.Generic;
@@ -17,64 +17,12 @@
}
public int NPCID;
- public int NPCType;
- public string MODE;
- public string charName;
- public int NPCLV;
- public float ModleHeight;
- public float ModelRadius;
- public float ModeProportion;
- public Vector3 UIModeLOffset;
- public float UIModeLProportion;
- public Vector3 UIModelRotation;
- public int CanDeadFly;
+ public string NPCName;
public int Country;
- public int MinAtk;
- public int MaxAtk;
- public int Def;
- public int Realm;
- public int PoisionAtk;
- public int FireAtk;
- public int IceAtk;
- public int PoisionDef;
- public int IceDef;
- public int ThunderDef;
- public int AtkInterval;
- public int Hit;
- public int MissRate;
- public int SuperHiteRate;
- public int OrgSpeed;
- public int MoveType;
- public int AtkDist;
- public int Skill1;
- public int Skill2;
- public int Skill3;
- public int Skill4;
- public int Skill5;
- public int Skill6;
- public int Skill7;
- public int Skill8;
- public int AtkType;
- public int Sight;
- public int MoveArea;
- public int DHP;
- public int MaxHPEx;
- public int IsBoss;
- public int SP;
- public int AIType;
- public int CanAttack;
- public float weight;
- public string HeadPortrait;
- public int Show;
- public int AtkFeedback;
- public int hurtFeedback;
- public int AutomaticFace;
- public int Dig;
- public int[] Sounds;
- public int LifeBarCount;
- public int NPCEffect;
- public int NPCSpeakID;
- public string Equips;
+ public int AtkDistType;
+ public int LV;
+ public int SkinID;
+ public float ModelScale;
public override int LoadKey(string _key)
{
@@ -88,133 +36,17 @@
string[] tables = input.Split('\t');
int.TryParse(tables[0],out NPCID);
- int.TryParse(tables[1],out NPCType);
+ NPCName = tables[1];
- MODE = tables[2];
+ int.TryParse(tables[2],out Country);
- charName = tables[3];
+ int.TryParse(tables[3],out AtkDistType);
- int.TryParse(tables[4],out NPCLV);
+ int.TryParse(tables[4],out LV);
- float.TryParse(tables[5],out ModleHeight);
+ int.TryParse(tables[5],out SkinID);
- float.TryParse(tables[6],out ModelRadius);
-
- float.TryParse(tables[7],out ModeProportion);
-
- UIModeLOffset=tables[8].Vector3Parse();
-
- float.TryParse(tables[9],out UIModeLProportion);
-
- UIModelRotation=tables[10].Vector3Parse();
-
- int.TryParse(tables[11],out CanDeadFly);
-
- int.TryParse(tables[12],out Country);
-
- int.TryParse(tables[13],out MinAtk);
-
- int.TryParse(tables[14],out MaxAtk);
-
- int.TryParse(tables[15],out Def);
-
- int.TryParse(tables[16],out Realm);
-
- int.TryParse(tables[17],out PoisionAtk);
-
- int.TryParse(tables[18],out FireAtk);
-
- int.TryParse(tables[19],out IceAtk);
-
- int.TryParse(tables[20],out PoisionDef);
-
- int.TryParse(tables[21],out IceDef);
-
- int.TryParse(tables[22],out ThunderDef);
-
- int.TryParse(tables[23],out AtkInterval);
-
- int.TryParse(tables[24],out Hit);
-
- int.TryParse(tables[25],out MissRate);
-
- int.TryParse(tables[26],out SuperHiteRate);
-
- int.TryParse(tables[27],out OrgSpeed);
-
- int.TryParse(tables[28],out MoveType);
-
- int.TryParse(tables[29],out AtkDist);
-
- int.TryParse(tables[30],out Skill1);
-
- int.TryParse(tables[31],out Skill2);
-
- int.TryParse(tables[32],out Skill3);
-
- int.TryParse(tables[33],out Skill4);
-
- int.TryParse(tables[34],out Skill5);
-
- int.TryParse(tables[35],out Skill6);
-
- int.TryParse(tables[36],out Skill7);
-
- int.TryParse(tables[37],out Skill8);
-
- int.TryParse(tables[38],out AtkType);
-
- int.TryParse(tables[39],out Sight);
-
- int.TryParse(tables[40],out MoveArea);
-
- int.TryParse(tables[41],out DHP);
-
- int.TryParse(tables[42],out MaxHPEx);
-
- int.TryParse(tables[43],out IsBoss);
-
- int.TryParse(tables[44],out SP);
-
- int.TryParse(tables[45],out AIType);
-
- int.TryParse(tables[46],out CanAttack);
-
- float.TryParse(tables[47],out weight);
-
- HeadPortrait = tables[48];
-
- int.TryParse(tables[49],out Show);
-
- int.TryParse(tables[50],out AtkFeedback);
-
- int.TryParse(tables[51],out hurtFeedback);
-
- int.TryParse(tables[52],out AutomaticFace);
-
- int.TryParse(tables[53],out Dig);
-
- if (tables[54].Contains("["))
- {
- Sounds = JsonMapper.ToObject<int[]>(tables[54]);
- }
- else
- {
- string[] SoundsStringArray = tables[54].Trim().Split(StringUtility.splitSeparator,StringSplitOptions.RemoveEmptyEntries);
- Sounds = new int[SoundsStringArray.Length];
- for (int i=0;i<SoundsStringArray.Length;i++)
- {
- int.TryParse(SoundsStringArray[i],out Sounds[i]);
- }
- }
-
- int.TryParse(tables[55],out LifeBarCount);
-
- int.TryParse(tables[56],out NPCEffect);
-
- int.TryParse(tables[57],out NPCSpeakID);
-
- Equips = tables[58];
+ float.TryParse(tables[6],out ModelScale);
}
catch (Exception exception)
{
diff --git a/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs b/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
index d336c38..ed9c008 100644
--- a/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
+++ b/Main/Core/NetworkPackage/CustomServerPack/CustomHB426CombinePack.cs
@@ -139,14 +139,31 @@
return;
}
- // 鎶�鑳藉寘
+ var skillAction = CreateSkillAction();
+ if (null != skillAction)
+ {
+ battleField.PlayRecord(skillAction);
+ }
+ }
+
+ public SkillRecordAction CreateSkillAction()
+ {
+ BattleField battleField = BattleManager.Instance.GetBattleField(guid);
+
+ if (null == battleField)
+ {
+ Debug.LogError("BattleField not found for guid: " + guid);
+ return null;
+ }
+
if (startTag.Tag.StartsWith("Skill_"))
{
- H0604_tagUseSkillAttack skill = packList[0] as H0604_tagUseSkillAttack;
- BattleObject caster = battleField.battleObjMgr.GetBattleObject((int)skill.ObjID);
- // 娉ㄦ剰澶勭悊packList
- SkillRecordAction skillRecordAction = new SkillRecordAction(battleField, caster, skill, packList);
- battleField.PlayRecord(skillRecordAction);
+ HB427_tagSCUseSkill skill = packList[0] as HB427_tagSCUseSkill;
+ BattleObject _caster = battleField.battleObjMgr.GetBattleObject((int)skill.ObjID);
+ SkillRecordAction skillAction = new SkillRecordAction(battleField, _caster, skill, packList);
+ return skillAction;
}
+
+ return null;
}
}
\ No newline at end of file
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0407_tagNPCDisappear.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0407_tagNPCDisappear.cs
index 5c2c2ea..c3097f1 100644
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0407_tagNPCDisappear.cs
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0407_tagNPCDisappear.cs
@@ -4,7 +4,8 @@
//04 07 NPC娑堝け#tagNPCDisappear
public class DTC0407_tagNPCDisappear : DtcBasic {
- public override void Done(GameNetPackBasic vNetPack) {
+ public override void Done(GameNetPackBasic vNetPack)
+ {
base.Done(vNetPack);
H0407_tagNPCDisappear vNetData = vNetPack as H0407_tagNPCDisappear;
@@ -14,6 +15,7 @@
//04 07 NPC娑堝け#tagNPCDisappear 涓殑瀛楁NPCID瀹為檯涓婂悓姝ョ殑鏄疧bjID锛屽彧鏄懡鍚嶉棶棰�
// 鎻愬墠缁撴潫鎴樻枟 鍒犻櫎NPCID锛堬級瀹為檯涓婃槸瀵硅薄鐨凮bjID
battleField.NPCDisappear(vNetData.NPCID);
+ battleField.DistributeNextPackage();
}
}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0418_tagObjInfoRefresh.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0418_tagObjInfoRefresh.cs
index 20f4fe7..a78cb09 100644
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0418_tagObjInfoRefresh.cs
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0418_tagObjInfoRefresh.cs
@@ -21,7 +21,6 @@
UpdateBattleField(vNetData);
break;
default:
- Debug.LogError("DTC0418_tagObjInfoRefresh 鏈嶅姟绔悓姝ヤ簡涓�涓湭鐭ョ被鍨嬬殑ObjType鐨勫埛鏂� " + vNetData.ObjType);
break;
}
}
@@ -40,10 +39,11 @@
//_player.UpdateData(vNetData);
}
}
-
+
public static void UpdateBattleField(H0418_tagObjInfoRefresh vNetData)
{
BattleField battleField = BattleManager.Instance.GetBattleField(vNetData.packUID);
battleField.ObjInfoRefresh(vNetData);
+ battleField.DistributeNextPackage();
}
}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs
deleted file mode 100644
index 971c280..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs
+++ /dev/null
@@ -1,24 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//04 23 瀵硅薄鐘舵�佸埛鏂伴�氱煡(鍙樉绀�)#tagObjPropertyRefreshView
-
-public class DTC0423_tagObjPropertyRefreshView : DtcBasic {
- public override void Done(GameNetPackBasic vNetPack) {
- base.Done(vNetPack);
- H0423_tagObjPropertyRefreshView vNetData = vNetPack as H0423_tagObjPropertyRefreshView;
-
- // public uint ObjID; //瀵硅薄ID
- // public byte ObjType; //瀵硅薄绫诲瀷
- // public uint SkillID; //鎶�鑳絀D
- // public uint DiffValue; //鍊�
- // public uint DiffValueEx; //瓒呬嚎鍊�
- // public byte AttackType; //鏀诲嚮绫诲瀷
- // public uint SrcObjID; //椋樿鏉ユ簮
- // public byte SrcObjType;
- // public uint HP; //鍓╀綑琛�閲�
- // public uint HPEx; //鍓╀綑琛�閲� 浜�
- BattleField battleField = BattleManager.Instance.GetBattleField(vNetPack.packUID);
- battleField.ObjPropertyRefreshView(vNetData);
- }
-}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs.meta
deleted file mode 100644
index f3b0890..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H04_Scene/DTC0423_tagObjPropertyRefreshView.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: a684ee13a4781a84f90648f120768a0f
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs
deleted file mode 100644
index ecf4920..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs
+++ /dev/null
@@ -1,29 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 04 鎶�鑳芥敾鍑讳娇鐢ㄦ垚鍔�#tagUseSkillAttack
-
-public class DTC0604_tagUseSkillAttack : DtcBasic {
- public override void Done(GameNetPackBasic vNetPack) {
- base.Done(vNetPack);
- // H0604_tagUseSkillAttack vNetData = vNetPack as H0604_tagUseSkillAttack;
-
-
- // public uint ObjID;
- // public byte ObjType;
- // public byte BattleType; //鐗╃悊/榄旀硶
- // public ushort SkillID;
- // public uint AttackID; //涓绘敾鍑荤洰鏍�
- // public byte AttackObjType; //涓绘敾鍑荤洰鏍�
- // public ushort HurtCount; //浼ゅ鏁扮洰
- // public tagSkillHurtObj[] HurtList; //size = HurtCount
-
- // ObjType绫诲瀷鐨凮bjID浣跨敤BattleType绫绘妧鑳絊killID鏀诲嚮浜咥ttackObjType绫诲瀷鐨凙ttackID 浼ゅ鏁板瓧鏄疕urtList
-
- // BattleField battleField = BattleManager.Instance.GetBattleField(vNetPack.packUID);
-
- // battleField.ProcessUseSkillAttack(vNetData);
-
-
- }
-}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs.meta
deleted file mode 100644
index 3d63884..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0604_tagUseSkillAttack.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 549309953c5bf6840905da3884455347
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs
deleted file mode 100644
index d760c3b..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs
+++ /dev/null
@@ -1,23 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 05 瀵硅薄澧炲姞Buf#tagObjAddBuff
-
-public class DTC0605_tagObjAddBuff : DtcBasic {
- public override void Done(GameNetPackBasic vNetPack)
- {
- base.Done(vNetPack);
- H0605_tagObjAddBuff vNetData = vNetPack as H0605_tagObjAddBuff;
-
- BattleField battleField = BattleManager.Instance.GetBattleField(vNetData.packUID);
-
- BattleObject vBattleObject = battleField.battleObjMgr.GetBattleObject((int)vNetData.ObjID);
-
- if (null == vBattleObject)
- {
- return;
- }
-
- vBattleObject.buffMgr.AddBuff(vNetData);
- }
-}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs.meta
deleted file mode 100644
index 41346b9..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0605_tagObjAddBuff.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: ab22a1e1dbaa6804ba19406c7ad3437c
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs
deleted file mode 100644
index 8f80850..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs
+++ /dev/null
@@ -1,11 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 06 瀵硅薄鍑忓皯Buf#tagObjDelBuff
-
-public class DTC0606_tagObjDelBuff : DtcBasic {
- public override void Done(GameNetPackBasic vNetPack) {
- base.Done(vNetPack);
- H0606_tagObjDelBuff vNetData = vNetPack as H0606_tagObjDelBuff;
- }
-}
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs.meta
deleted file mode 100644
index c06ac8f..0000000
--- a/Main/Core/NetworkPackage/DTCFile/ServerPack/H06_PlayerVsNPC/DTC0606_tagObjDelBuff.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 15cb5f876af39584590fb067a6f11bc2
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs
new file mode 100644
index 0000000..cd37b5c
--- /dev/null
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs
@@ -0,0 +1,11 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 18 瀵硅薄灞炴�у埛鏂板睍绀� #tagSCObjPropertyRefreshView
+
+public class DTCB418_tagSCObjPropertyRefreshView : DtcBasic {
+ public override void Done(GameNetPackBasic vNetPack) {
+ base.Done(vNetPack);
+ HB418_tagSCObjPropertyRefreshView vNetData = vNetPack as HB418_tagSCObjPropertyRefreshView;
+ }
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs.meta
index 16feec2..8024e6c 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB418_tagSCObjPropertyRefreshView.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: a41a3888866561f46bf02d8943cd5cc9
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs
new file mode 100644
index 0000000..a5ed6c7
--- /dev/null
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs
@@ -0,0 +1,11 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 27 浣跨敤鎶�鑳� #tagSCUseSkill
+
+public class DTCB427_tagSCUseSkill : DtcBasic {
+ public override void Done(GameNetPackBasic vNetPack) {
+ base.Done(vNetPack);
+ HB427_tagSCUseSkill vNetData = vNetPack as HB427_tagSCUseSkill;
+ }
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs.meta
index 16feec2..38e3eed 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB427_tagSCUseSkill.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: 88b19efc6dc41c54da0a86efa91e2ee6
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs
new file mode 100644
index 0000000..fb6ab65
--- /dev/null
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs
@@ -0,0 +1,11 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 28 Buff鍒锋柊 #tagSCBuffRefresh
+
+public class DTCB428_tagSCBuffRefresh : DtcBasic {
+ public override void Done(GameNetPackBasic vNetPack) {
+ base.Done(vNetPack);
+ HB428_tagSCBuffRefresh vNetData = vNetPack as HB428_tagSCBuffRefresh;
+ }
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs.meta
index 16feec2..5183b4f 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB428_tagSCBuffRefresh.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: bbdd35a17a2229046a33c75f4bd536c6
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs
new file mode 100644
index 0000000..bf2f248
--- /dev/null
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs
@@ -0,0 +1,11 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 29 Buff娑堝け #tagSCBuffDel
+
+public class DTCB429_tagSCBuffDel : DtcBasic {
+ public override void Done(GameNetPackBasic vNetPack) {
+ base.Done(vNetPack);
+ HB429_tagSCBuffDel vNetData = vNetPack as HB429_tagSCBuffDel;
+ }
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs.meta
index 16feec2..7ec0830 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/DTCFile/ServerPack/HB4_FightDefine/DTCB429_tagSCBuffDel.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: 18ef61012c08d0742a2a50763b38c4ee
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/DataToCtl/PackageRegedit.cs b/Main/Core/NetworkPackage/DataToCtl/PackageRegedit.cs
index 959a91d..6ecf68a 100644
--- a/Main/Core/NetworkPackage/DataToCtl/PackageRegedit.cs
+++ b/Main/Core/NetworkPackage/DataToCtl/PackageRegedit.cs
@@ -49,8 +49,8 @@
Register(typeof(HA709_tagObjInfoListRefresh), typeof(DTCA709_tagObjInfoListRefresh));
Register(typeof(H0113_tagServerHeart), typeof(DTC0113_tagServerHeart));
Register(typeof(H0111_tagOnlineReply), typeof(DTC0111_tagOnlineReply));
- Register(typeof(H0605_tagObjAddBuff), typeof(DTC0605_tagObjAddBuff));
- Register(typeof(H0606_tagObjDelBuff), typeof(DTC0606_tagObjDelBuff));
+ Register(typeof(HB428_tagSCBuffRefresh), typeof(DTCB428_tagSCBuffRefresh));
+ Register(typeof(HB429_tagSCBuffDel), typeof(DTCB429_tagSCBuffDel));
Register(typeof(H0608_tagNPCDie), typeof(DTC0608_tagNPCDie));
Register(typeof(H0612_tagClearObjBuff), typeof(DTC0612_tagClearObjBuff));
Register(typeof(HA3A1_tagMCModuleFightPowerInfo), typeof(DTCA3A1_tagMCModuleFightPowerInfo));
@@ -100,8 +100,8 @@
Register(typeof(HB425_tagSCTurnFightReportSign), typeof(DTCB425_tagSCTurnFightReportSign));
Register(typeof(HB430_tagSCTurnFightReport), typeof(DTCB430_tagSCTurnFightReport));
Register(typeof(H0407_tagNPCDisappear), typeof(DTC0407_tagNPCDisappear));
- Register(typeof(H0423_tagObjPropertyRefreshView), typeof(DTC0423_tagObjPropertyRefreshView));
- Register(typeof(H0604_tagUseSkillAttack), typeof(DTC0604_tagUseSkillAttack));
+ Register(typeof(HB418_tagSCObjPropertyRefreshView), typeof(DTCB418_tagSCObjPropertyRefreshView));
+ Register(typeof(HB427_tagSCUseSkill), typeof(DTCB427_tagSCUseSkill));
Register(typeof(HB124_tagSCLineupInfo), typeof(DTCB124_tagSCLineupInfo));
Register(typeof(HA207_tagSCPackBuyInfo), typeof(DTCA207_tagSCPackBuyInfo));
}
diff --git a/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs b/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs
deleted file mode 100644
index 4d883f5..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs
+++ /dev/null
@@ -1,35 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//04 23 瀵硅薄鐘舵�佸埛鏂伴�氱煡(鍙樉绀�)#tagObjPropertyRefreshView
-
-public class H0423_tagObjPropertyRefreshView : GameNetPackBasic {
- public uint ObjID; //瀵硅薄ID
- public byte ObjType; //瀵硅薄绫诲瀷
- public uint SkillID; //鎶�鑳絀D
- public uint DiffValue; //鍊�
- public uint DiffValueEx; //瓒呬嚎鍊�
- public byte AttackType; //鏀诲嚮绫诲瀷
- public uint SrcObjID; //椋樿鏉ユ簮
- public byte SrcObjType;
- public uint HP; //鍓╀綑琛�閲�
- public uint HPEx; //鍓╀綑琛�閲� 浜�
-
- public H0423_tagObjPropertyRefreshView () {
- _cmd = (ushort)0x0423;
- }
-
- public override void ReadFromBytes (byte[] vBytes) {
- TransBytes (out ObjID, vBytes, NetDataType.DWORD);
- TransBytes (out ObjType, vBytes, NetDataType.BYTE);
- TransBytes (out SkillID, vBytes, NetDataType.DWORD);
- TransBytes (out DiffValue, vBytes, NetDataType.DWORD);
- TransBytes (out DiffValueEx, vBytes, NetDataType.DWORD);
- TransBytes (out AttackType, vBytes, NetDataType.BYTE);
- TransBytes (out SrcObjID, vBytes, NetDataType.DWORD);
- TransBytes (out SrcObjType, vBytes, NetDataType.BYTE);
- TransBytes (out HP, vBytes, NetDataType.DWORD);
- TransBytes (out HPEx, vBytes, NetDataType.DWORD);
- }
-
-}
diff --git a/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs.meta b/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs.meta
deleted file mode 100644
index 87fada6..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H04_Scene/H0423_tagObjPropertyRefreshView.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 48ce6558ac407c34f8988dbe9b810da4
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs b/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs
deleted file mode 100644
index a497eb6..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs
+++ /dev/null
@@ -1,51 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 04 鎶�鑳芥敾鍑讳娇鐢ㄦ垚鍔�#tagUseSkillAttack
-
-public class H0604_tagUseSkillAttack : GameNetPackBasic {
- public uint ObjID;
- public byte ObjType;
- public byte BattleType; //鐗╃悊/榄旀硶
- public ushort SkillID;
- public uint AttackID; //涓绘敾鍑荤洰鏍�
- public byte AttackObjType; //涓绘敾鍑荤洰鏍�
- public ushort HurtCount; //浼ゅ鏁扮洰
- public tagSkillHurtObj[] HurtList; //size = HurtCount
-
- public H0604_tagUseSkillAttack () {
- _cmd = (ushort)0x0604;
- }
-
- public override void ReadFromBytes (byte[] vBytes) {
- TransBytes (out ObjID, vBytes, NetDataType.DWORD);
- TransBytes (out ObjType, vBytes, NetDataType.BYTE);
- TransBytes (out BattleType, vBytes, NetDataType.BYTE);
- TransBytes (out SkillID, vBytes, NetDataType.WORD);
- TransBytes (out AttackID, vBytes, NetDataType.DWORD);
- TransBytes (out AttackObjType, vBytes, NetDataType.BYTE);
- TransBytes (out HurtCount, vBytes, NetDataType.WORD);
- HurtList = new tagSkillHurtObj[HurtCount];
- for (int i = 0; i < HurtCount; i ++) {
- HurtList[i] = new tagSkillHurtObj();
- TransBytes (out HurtList[i].ObjType, vBytes, NetDataType.BYTE);
- TransBytes (out HurtList[i].ObjID, vBytes, NetDataType.DWORD);
- TransBytes (out HurtList[i].AttackType, vBytes, NetDataType.BYTE);
- TransBytes (out HurtList[i].HurtHP, vBytes, NetDataType.DWORD);
- TransBytes (out HurtList[i].HurtHPEx, vBytes, NetDataType.DWORD);
- TransBytes (out HurtList[i].CurHP, vBytes, NetDataType.DWORD);
- TransBytes (out HurtList[i].CurHPEx, vBytes, NetDataType.DWORD);
- }
- }
-
- public struct tagSkillHurtObj {
- public byte ObjType;
- public uint ObjID;
- public byte AttackType; //鐖嗗嚮, miss
- public uint HurtHP;
- public uint HurtHPEx;
- public uint CurHP;
- public uint CurHPEx;
- }
-
-}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs.meta b/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs.meta
deleted file mode 100644
index 298d80f..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0604_tagUseSkillAttack.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: 4e187e9798104844f924234a78385c0d
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs b/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs
deleted file mode 100644
index f15875d..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs
+++ /dev/null
@@ -1,37 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 05 瀵硅薄澧炲姞Buf#tagObjAddBuff
-
-public class H0605_tagObjAddBuff : GameNetPackBasic {
- public byte ObjType; //buff鐨勫彈鏁堟灉鑰�
- public uint ObjID;
- public byte BuffType; //Buff绫诲瀷 TBuffType
- public ushort SkillID;
- public uint LastTime;
- public uint Value;
- public uint Value1;
- public uint Value2;
- public byte Layer; //灞傛暟锛屼笉闇�瑕侀粯璁�0
- public uint OwnerID; // buff鏉ユ簮鑰�
- public byte OwnerType;
-
- public H0605_tagObjAddBuff () {
- _cmd = (ushort)0x0605;
- }
-
- public override void ReadFromBytes (byte[] vBytes) {
- TransBytes (out ObjType, vBytes, NetDataType.BYTE);
- TransBytes (out ObjID, vBytes, NetDataType.DWORD);
- TransBytes (out BuffType, vBytes, NetDataType.BYTE);
- TransBytes (out SkillID, vBytes, NetDataType.WORD);
- TransBytes (out LastTime, vBytes, NetDataType.DWORD);
- TransBytes (out Value, vBytes, NetDataType.DWORD);
- TransBytes (out Value1, vBytes, NetDataType.DWORD);
- TransBytes (out Value2, vBytes, NetDataType.DWORD);
- TransBytes (out Layer, vBytes, NetDataType.BYTE);
- TransBytes (out OwnerID, vBytes, NetDataType.DWORD);
- TransBytes (out OwnerType, vBytes, NetDataType.BYTE);
- }
-
-}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs b/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs
deleted file mode 100644
index 1490618..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs
+++ /dev/null
@@ -1,23 +0,0 @@
-using UnityEngine;
-using System.Collections;
-
-//06 06 瀵硅薄鍑忓皯Buf#tagObjDelBuff
-
-public class H0606_tagObjDelBuff : GameNetPackBasic {
- public byte ObjType;
- public uint ObjID;
- public byte BuffType;
- public ushort SkillID;
-
- public H0606_tagObjDelBuff () {
- _cmd = (ushort)0x0606;
- }
-
- public override void ReadFromBytes (byte[] vBytes) {
- TransBytes (out ObjType, vBytes, NetDataType.BYTE);
- TransBytes (out ObjID, vBytes, NetDataType.DWORD);
- TransBytes (out BuffType, vBytes, NetDataType.BYTE);
- TransBytes (out SkillID, vBytes, NetDataType.WORD);
- }
-
-}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs.meta b/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs.meta
deleted file mode 100644
index 1d33f0c..0000000
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0606_tagObjDelBuff.cs.meta
+++ /dev/null
@@ -1,11 +0,0 @@
-fileFormatVersion: 2
-guid: b98c2ae3ef253814189edb8d9fe00b5a
-MonoImporter:
- externalObjects: {}
- serializedVersion: 2
- defaultReferences: []
- executionOrder: 0
- icon: {instanceID: 0}
- userData:
- assetBundleName:
- assetBundleVariant:
diff --git a/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs
new file mode 100644
index 0000000..3d788c7
--- /dev/null
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs
@@ -0,0 +1,33 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 18 瀵硅薄灞炴�у埛鏂板睍绀� #tagSCObjPropertyRefreshView
+
+public class HB418_tagSCObjPropertyRefreshView : GameNetPackBasic {
+ public uint ObjID;
+ public ushort RefreshType; // 鍚�0418鍒锋柊绫诲瀷锛屽琛�閲忋�佹�掓皵
+ public uint Value; // 鏇存柊鍊�
+ public uint ValueEx; // 鏇存柊鍊硷紝濡傛灉鏄ぇ鏁板�肩殑姝ゅ�间负鏁撮櫎浜块儴鍒�
+ public byte DiffType; // 鍙樺寲绫诲瀷锛�0-鍑忓皯锛�1-澧炲姞
+ public uint DiffValue; // 鍙樺寲鍊�
+ public uint DiffValueEx; // 鍙樺寲鍊硷紝濡傛灉鏄ぇ鏁板�肩殑姝ゅ�间负鏁撮櫎浜块儴鍒�
+ public uint SkillID; // 浣跨敤鐨勬妧鑳借〃ID
+ public uint RelatedSkillID; // 鍏宠仈鐨勬妧鑳絀D锛屼竴鑸槸涓绘妧鑳絀D锛岄潪涓绘妧鑳介澶栬Е鍙戠殑涓�0
+
+ public HB418_tagSCObjPropertyRefreshView () {
+ _cmd = (ushort)0xB418;
+ }
+
+ public override void ReadFromBytes (byte[] vBytes) {
+ TransBytes (out ObjID, vBytes, NetDataType.DWORD);
+ TransBytes (out RefreshType, vBytes, NetDataType.WORD);
+ TransBytes (out Value, vBytes, NetDataType.DWORD);
+ TransBytes (out ValueEx, vBytes, NetDataType.DWORD);
+ TransBytes (out DiffType, vBytes, NetDataType.BYTE);
+ TransBytes (out DiffValue, vBytes, NetDataType.DWORD);
+ TransBytes (out DiffValueEx, vBytes, NetDataType.DWORD);
+ TransBytes (out SkillID, vBytes, NetDataType.DWORD);
+ TransBytes (out RelatedSkillID, vBytes, NetDataType.DWORD);
+ }
+
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs.meta
similarity index 83%
rename from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
rename to Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs.meta
index 16feec2..dbb7f49 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB418_tagSCObjPropertyRefreshView.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: 90ecbff2c649bc74f8a6d199342eda64
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs
new file mode 100644
index 0000000..159725d
--- /dev/null
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs
@@ -0,0 +1,53 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 27 浣跨敤鎶�鑳� #tagSCUseSkill
+
+public class HB427_tagSCUseSkill : GameNetPackBasic {
+ public uint ObjID;
+ public byte PMType; // 鐗╂硶绫诲瀷 0鎴�1-鐗╃悊锛�2-娉曟湳
+ public byte BattleType; // 鎴樻枟绫诲瀷 0-甯歌锛�1-杩炲嚮锛�2-鍙嶅嚮锛�3-杩藉嚮
+ public uint CurHP; // 閲婃斁鎶�鑳藉悗鍓╀綑琛�閲忥紝鍚歌銆佸弽寮瑰彲鑳藉紩璧峰彉鍖栵紝姹備綑浜块儴鍒�
+ public uint CurHPEx; // 閲婃斁鎶�鑳藉悗鍓╀綑琛�閲忥紝鍚歌銆佸弽寮瑰彲鑳藉紩璧峰彉鍖栵紝鏁撮櫎浜块儴鍒�
+ public uint SkillID;
+ public byte HurtCount; //浼ゅ鏁扮洰
+ public tagSCUseSkillHurt[] HurtList; //size = HurtCount
+
+ public HB427_tagSCUseSkill () {
+ _cmd = (ushort)0xB427;
+ }
+
+ public override void ReadFromBytes (byte[] vBytes) {
+ TransBytes (out ObjID, vBytes, NetDataType.DWORD);
+ TransBytes (out PMType, vBytes, NetDataType.BYTE);
+ TransBytes (out BattleType, vBytes, NetDataType.BYTE);
+ TransBytes (out CurHP, vBytes, NetDataType.DWORD);
+ TransBytes (out CurHPEx, vBytes, NetDataType.DWORD);
+ TransBytes (out SkillID, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtCount, vBytes, NetDataType.BYTE);
+ HurtList = new tagSCUseSkillHurt[HurtCount];
+ for (int i = 0; i < HurtCount; i ++) {
+ HurtList[i] = new tagSCUseSkillHurt();
+ TransBytes (out HurtList[i].ObjID, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].AttackTypes, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].HurtHP, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].HurtHPEx, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].CurHP, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].CurHPEx, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].SuckHP, vBytes, NetDataType.DWORD);
+ TransBytes (out HurtList[i].BounceHP, vBytes, NetDataType.DWORD);
+ }
+ }
+
+ public struct tagSCUseSkillHurt {
+ public uint ObjID;
+ public uint AttackTypes; // 椋樿绫诲瀷姹囨�伙紝鏀寔澶氱绫诲瀷骞跺瓨锛屽鏃犺闃插尽涓旀毚鍑诲悓鏃惰鏍兼尅锛屼簩杩涘埗鎴栬繍绠楁渶缁堝�硷紱0-澶辫触锛�1-鏅�氾紱2-鍥炶锛�5-鏍兼尅锛�6-鏃犺闃插尽锛�7-鏆村嚮锛�9-闂伩
+ public uint HurtHP; // 椋樿鍊硷紝姹備綑浜块儴鍒�
+ public uint HurtHPEx; // 椋樿鍊硷紝鏁撮櫎浜块儴鍒�
+ public uint CurHP; // 鏇存柊鍓╀綑琛�閲忥紝姹備綑浜块儴鍒�
+ public uint CurHPEx; // 鏇存柊鍓╀綑琛�閲忥紝鏁撮櫎浜块儴鍒�
+ public uint SuckHP; // 鏈浼ゅ杞寲鐨勫惛琛�閲�
+ public uint BounceHP; // 鏈浼ゅ鍙嶅脊鐨勪激瀹抽噺
+ }
+
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs.meta
index 16feec2..1e8d043 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB427_tagSCUseSkill.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: e5c311adce9738447b17d657a67f711e
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs
new file mode 100644
index 0000000..17c98dd
--- /dev/null
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs
@@ -0,0 +1,29 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 28 Buff鍒锋柊 #tagSCBuffRefresh
+
+public class HB428_tagSCBuffRefresh : GameNetPackBasic {
+ public uint ObjID; // 璋佽韩涓婄殑buff
+ public uint BuffID; // buffID锛屾煇涓猳bj涓婄殑鍞竴buffID锛屼笉鍚岀殑buffID鍙兘skillID鐩稿悓
+ public uint SkillID; // 璇uff瀵瑰簲鎶�鑳借〃ID
+ public uint RelatedSkillID; // 鍏宠仈鐨勬妧鑳絀D锛屼竴鑸槸涓绘妧鑳絀D鎴栫敱浜庢煇涓妧鑳介噴鏀惧紩璧风殑buff鍙樻洿
+ public uint LastTime; // 鍓╀綑鏃堕暱姣/鍥炲悎鏁�
+ public ushort Layer; // 灞傛暟锛屼笉闇�瑕侀粯璁�0
+ public uint OwnerID; // buff鏉ユ簮鑰咃紝鍗虫柦娉曟柟
+
+ public HB428_tagSCBuffRefresh () {
+ _cmd = (ushort)0xB428;
+ }
+
+ public override void ReadFromBytes (byte[] vBytes) {
+ TransBytes (out ObjID, vBytes, NetDataType.DWORD);
+ TransBytes (out BuffID, vBytes, NetDataType.DWORD);
+ TransBytes (out SkillID, vBytes, NetDataType.DWORD);
+ TransBytes (out RelatedSkillID, vBytes, NetDataType.DWORD);
+ TransBytes (out LastTime, vBytes, NetDataType.DWORD);
+ TransBytes (out Layer, vBytes, NetDataType.WORD);
+ TransBytes (out OwnerID, vBytes, NetDataType.DWORD);
+ }
+
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs.meta
index 16feec2..795a62e 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB428_tagSCBuffRefresh.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: de6aee33096382147b9b96764707a505
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs
new file mode 100644
index 0000000..44cdec3
--- /dev/null
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs
@@ -0,0 +1,21 @@
+using UnityEngine;
+using System.Collections;
+
+// B4 29 Buff娑堝け #tagSCBuffDel
+
+public class HB429_tagSCBuffDel : GameNetPackBasic {
+ public uint ObjID;
+ public uint BuffID;
+ public uint RelatedSkillID; // 鍏宠仈鐨勬妧鑳絀D锛屼竴鑸槸涓绘妧鑳絀D鎴栫敱浜庢煇涓妧鑳介噴鏀惧紩璧风殑buff鍙樻洿
+
+ public HB429_tagSCBuffDel () {
+ _cmd = (ushort)0xB429;
+ }
+
+ public override void ReadFromBytes (byte[] vBytes) {
+ TransBytes (out ObjID, vBytes, NetDataType.DWORD);
+ TransBytes (out BuffID, vBytes, NetDataType.DWORD);
+ TransBytes (out RelatedSkillID, vBytes, NetDataType.DWORD);
+ }
+
+}
diff --git a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs.meta
similarity index 83%
copy from Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
copy to Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs.meta
index 16feec2..2738bb9 100644
--- a/Main/Core/NetworkPackage/ServerPack/H06_PlayerVsNPC/H0605_tagObjAddBuff.cs.meta
+++ b/Main/Core/NetworkPackage/ServerPack/HB4_FightDefine/HB429_tagSCBuffDel.cs.meta
@@ -1,5 +1,5 @@
fileFormatVersion: 2
-guid: 6f36552c258dcd14fb30a3366bb16cf1
+guid: 474e26ca749e647429ea52a7eb429c59
MonoImporter:
externalObjects: {}
serializedVersion: 2
diff --git a/Main/System/Battle/BattleEffectMgr.cs b/Main/System/Battle/BattleEffectMgr.cs
index 8d507cc..c4607d7 100644
--- a/Main/System/Battle/BattleEffectMgr.cs
+++ b/Main/System/Battle/BattleEffectMgr.cs
@@ -99,4 +99,20 @@
}
effectDict.Clear();
}
+
+ public void Release()
+ {
+ foreach (var effect in effectDict)
+ {
+ foreach (var effectPlayer in effect.Value)
+ {
+ if (effectPlayer != null)
+ {
+ GameObject.DestroyImmediate(effectPlayer.gameObject);
+ }
+ }
+ }
+
+ effectDict.Clear();
+ }
}
\ No newline at end of file
diff --git a/Main/System/Battle/BattleField/BattleField.cs b/Main/System/Battle/BattleField/BattleField.cs
index 1335468..07c5ced 100644
--- a/Main/System/Battle/BattleField/BattleField.cs
+++ b/Main/System/Battle/BattleField/BattleField.cs
@@ -125,6 +125,9 @@
public virtual void Release()
{
battleObjMgr.Release();
+ battleEffectMgr.Release();
+ battleTweenMgr.Release();
+ recordPlayer.Release();
}
public virtual void Run()
@@ -265,7 +268,7 @@
}
}
- public void ObjPropertyRefreshView(H0423_tagObjPropertyRefreshView vNetData)
+ public void ObjPropertyRefreshView(HB418_tagSCObjPropertyRefreshView vNetData)
{
}
@@ -279,6 +282,7 @@
public virtual void Destroy()
{
// 閿�姣佸叏閮ㄥ唴瀹�
+ BattleManager.Instance.DestroyBattleField(this);
}
public void NPCDisappear(uint[] ObjIDArr)
@@ -371,8 +375,10 @@
}
// 鎾斁鎴樻枟寮�濮嬬殑鐗规晥
- var efplayer = battleEffectMgr.PlayEffect(0, BattleConst.BattleStartEffectID, battleRootNode.transform);
- efplayer.onDestroy += a => onMoveComplete();
+ // var efplayer = battleEffectMgr.PlayEffect(0, BattleConst.BattleStartEffectID, battleRootNode.transform);
+ // efplayer.onDestroy += a => onMoveComplete();
+
+ onMoveComplete?.Invoke();
};
}
@@ -382,7 +388,7 @@
//鏃犺濡備綍鍥惧眰搴旇鍦ㄤ汉鐗╀笂闈� 鎵�浠ヨ繖閲屽簲璇ユ湁涓寕鐐�
// YYL TODO
-
+
}
public void OnObjReborn(HB423_tagMCTurnFightObjReborn vNetData)
@@ -429,4 +435,9 @@
{
return IsBattleFinish;
}
+
+ public virtual void DistributeNextPackage()
+ {
+
+ }
}
\ No newline at end of file
diff --git a/Main/System/Battle/BattleField/OperationAgent/HandModeOperationAgent.cs b/Main/System/Battle/BattleField/OperationAgent/HandModeOperationAgent.cs
index 636cc37..8e75dcf 100644
--- a/Main/System/Battle/BattleField/OperationAgent/HandModeOperationAgent.cs
+++ b/Main/System/Battle/BattleField/OperationAgent/HandModeOperationAgent.cs
@@ -19,11 +19,14 @@
// 閫氳繃涓荤晫闈㈢殑鎸夐挳鎺ㄥ姩(璋冪敤)DoNext
public override void DoNext()
{
+ Debug.LogError("HandModeOperationAgent DoNext");
+
base.DoNext();
// 褰撳墠娌℃湁鍦ㄦ挱鏀炬垬鏂楀綍鍍�
if (!battleField.recordPlayer.IsPlaying())
{
+ Debug.LogError("HandModeOperationAgent DoNext 1");
// 娌℃湁涓嬩竴涓寘鍙互鍙戜簡
if (!BattleManager.Instance.DistributeNextPackage())
{
@@ -36,16 +39,14 @@
// 妫�鏌ヤ竴涓嬮敜瀛愮殑娑堣��
//FightPoint 鐢ㄤ簬璁板綍娑堣�楁垬閿ゅ�嶆暟锛屽皬浜庣瓑浜�1鏃堕粯璁�1鍊嶏紝澶т簬1鏃朵负瀵瑰簲娑堣�楀�嶅�硷紝0418鍒锋柊绫诲瀷22
+ Debug.LogError("HandModeOperationAgent DoNext 2");
ulong costRate = PlayerDatas.Instance.GetPlayerDataByType(PlayerDataType.FightPoint);
ulong cost = (costRate > 1 ? costRate : 1) * 1; // 1鏄粯璁ゆ秷鑰�
- // 妫�鏌ヤ竴涓嬮敜瀛愮殑娑堣��
- if (!ItemLogicUtility.CheckCurrencyCount(41, cost, true))
- {
- return;
- }
+
+ Debug.LogError("HandModeOperationAgent DoNext 3");
byte reqType;
if (storyBattleField.battleState == StoryBattleState.Break)
@@ -69,7 +70,22 @@
return;
}
+ Debug.LogError("HandModeOperationAgent DoNext 4 reqType is " + reqType);
+
+ // 妫�鏌ヤ竴涓嬮敜瀛愮殑娑堣��
+ if (!ItemLogicUtility.CheckCurrencyCount(41, cost, true))
+ {
+ return;
+ }
+
+ // 濡傛灉璇锋眰鐨勬槸2 璇存槑瑕佸垵濮嬪寲涓�涓嬫垬鍦�
BattleManager.Instance.MainFightRequest(reqType);
+
+ // 鍒濆鍖栨垬鍦哄悗鏈潵涓嶄細鑷姩鎵� 閭d箞灏遍渶瑕佸啀璇锋眰涓�娆�4缁х画鎴樻枟 鏉ュ紑濮嬫垬鏂�
+ if (reqType == 2)
+ {
+ BattleManager.Instance.MainFightRequest(4);
+ }
}
}
else
diff --git a/Main/System/Battle/BattleField/RecordActions/SkillRecordAction.cs b/Main/System/Battle/BattleField/RecordActions/SkillRecordAction.cs
index 0c11ba2..5a8d509 100644
--- a/Main/System/Battle/BattleField/RecordActions/SkillRecordAction.cs
+++ b/Main/System/Battle/BattleField/RecordActions/SkillRecordAction.cs
@@ -7,7 +7,7 @@
private bool isCast = false;
- public SkillRecordAction(BattleField _battleField, BattleObject _caster, H0604_tagUseSkillAttack vNetData, List<GameNetPackBasic> packList)
+ public SkillRecordAction(BattleField _battleField, BattleObject _caster, HB427_tagSCUseSkill vNetData, List<GameNetPackBasic> packList)
: base(RecordActionType.Skill, _battleField, _caster)
{
skillBase = SkillFactory.CreateSkill(_caster, vNetData, packList, _battleField);
diff --git a/Main/System/Battle/BattleField/StoryBattleField.cs b/Main/System/Battle/BattleField/StoryBattleField.cs
index c042d52..1d43c45 100644
--- a/Main/System/Battle/BattleField/StoryBattleField.cs
+++ b/Main/System/Battle/BattleField/StoryBattleField.cs
@@ -138,7 +138,7 @@
}
public override void OnBattleEnd(JsonData turnFightStateData)
- {
+ {
base.OnBattleEnd(turnFightStateData);
}
@@ -150,4 +150,10 @@
// base.Run();
// }
+
+ public override void DistributeNextPackage()
+ {
+ // 涓嶈璋冪敤base鐨勫嚱鏁�
+ BattleManager.Instance.DistributeNextPackage();
+ }
}
\ No newline at end of file
diff --git a/Main/System/Battle/BattleManager.cs b/Main/System/Battle/BattleManager.cs
index f0b92a1..630243f 100644
--- a/Main/System/Battle/BattleManager.cs
+++ b/Main/System/Battle/BattleManager.cs
@@ -323,6 +323,27 @@
return battleField;
}
+ public void DestroyBattleField(BattleField battleField)
+ {
+ if (battleField == null)
+ {
+ Debug.LogError("DestroyBattleField called with null battleField");
+ return;
+ }
+
+ string guid = battleField.guid;
+
+ if (battleFields.ContainsKey(guid))
+ {
+ battleFields.Remove(guid);
+ }
+
+ if (storyBattleField == battleField)
+ {
+ storyBattleField = null;
+ }
+ }
+
// 鐩墠鏀寔 BYTE ReqType; // 0-鍋滄鎴樻枟鍥炲煄锛�1-璁剧疆娑堣�楀�嶅�硷紱2-鎸戞垬鍏冲崱灏忔�紱3-鎸戞垬鍏冲崱boss锛�4-缁х画鎴樻枟锛�
// 0-鍋滄鎴樻枟鍥炲煄 - 鐜╁涓诲姩鐐瑰嚮鍥炲煄鏃跺彂閫�
diff --git a/Main/System/Battle/BattleObject/BattleObjMgr.cs b/Main/System/Battle/BattleObject/BattleObjMgr.cs
index 64c6db3..3c8cd0e 100644
--- a/Main/System/Battle/BattleObject/BattleObjMgr.cs
+++ b/Main/System/Battle/BattleObject/BattleObjMgr.cs
@@ -42,9 +42,8 @@
for (int i = 0; i < teamBase.serverHeroes.Length; i++)
{
TeamHero teamHero = teamBase.serverHeroes[i];
- if (teamHero != null)
+ if (teamHero != null && teamHero.heroId > 0)
{
-
BattleObject battleObj = BattleObjectFactory.CreateBattleObject(battleField, posNodeList, teamHero, _Camp);
allBattleObjDict.Add(battleObj.ObjID, battleObj);
campDict.Add(teamHero.positionNum, battleObj);
@@ -73,7 +72,7 @@
}
}
- public List<BattleObject> GetBattleObjList(H0604_tagUseSkillAttack tagUseSkillAttack)
+ public List<BattleObject> GetBattleObjList(HB427_tagSCUseSkill tagUseSkillAttack)
{
List<BattleObject> retList = new List<BattleObject>();
foreach (var hurt in tagUseSkillAttack.HurtList)
@@ -156,6 +155,7 @@
{
DestroyTeam(redCampDict);
DestroyTeam(blueCampDict);
+ allBattleObjDict.Clear();
}
public void Run()
diff --git a/Main/System/Battle/BattleObject/BattleObject.cs b/Main/System/Battle/BattleObject/BattleObject.cs
index 8c8aa5d..3abc1aa 100644
--- a/Main/System/Battle/BattleObject/BattleObject.cs
+++ b/Main/System/Battle/BattleObject/BattleObject.cs
@@ -225,7 +225,7 @@
return true;
}
- public virtual void Hurt(List<long> damageValues, long _totalDamage, int attackType)
+ public virtual void Hurt(List<long> damageValues, long _totalDamage, uint attackType)
{
PopDamage(teamHero.curHp, damageValues, attackType);
@@ -289,7 +289,7 @@
}
// 浼ゅ杩樿鐪� 鏄惁闂伩 鏆村嚮 and so on 闇�瑕佹湁涓�涓狣amageType 鏈嶅姟鍣ㄥ簲璇ヤ細缁�
- protected virtual void PopDamage(long curHp, List<long> damageValues, int attackType)
+ protected virtual void PopDamage(long curHp, List<long> damageValues, uint attackType)
{
// 鍏跺疄搴旇閫氱煡鍑哄幓缁橴I鐣岄潰瑙h�� 璁︰I鐣岄潰鑷繁鏉ユ樉绀虹殑 YYL TODO
// 鎾斁浼ゅ鏁板瓧
diff --git a/Main/System/Battle/BattleObject/BattleObjectFactory.cs b/Main/System/Battle/BattleObject/BattleObjectFactory.cs
index 60eb472..0ad9ec5 100644
--- a/Main/System/Battle/BattleObject/BattleObjectFactory.cs
+++ b/Main/System/Battle/BattleObject/BattleObjectFactory.cs
@@ -11,21 +11,44 @@
private static float modelScaleRate => float.Parse(FuncConfigConfig.Get("BattleModelScale").Numerical1);
+ // 杩欓噷鎶ラ敊浜嗘鏌ヤ竴涓�
public static BattleObject CreateBattleObject(BattleField _battleField, List<GameObject> posNodeList, TeamHero teamHero, BattleCamp _Camp)
{
HeroSkinConfig skinCfg = teamHero.skinConfig;
+ if (skinCfg == null)
+ {
+ Debug.LogError(teamHero.heroId + "BattleObjectFactory.CreateBattleObject: skinCfg is null for " + teamHero.SkinID);
+ return null;
+ }
+
GameObject battleGO = ResManager.Instance.LoadAsset<GameObject>("Hero/SpineRes", "Hero_001"/*skinCfg.SpineRes*/);
+
+ if (battleGO == null)
+ {
+ Debug.LogError("BattleObjectFactory.CreateBattleObject: battleGO is null for " + teamHero.heroId);
+ return null;
+ }
GameObject goParent = posNodeList[teamHero.positionNum];
BattleObject battleObject = new BattleObject(_battleField);
battleObject.ObjID = teamHero.ObjID;
GameObject realGO = GameObject.Instantiate(battleGO, goParent.transform);
- SkeletonGraphic skeletonGraphic = realGO.GetComponentInChildren<SkeletonGraphic>();
- skeletonGraphic.skeletonDataAsset = ResManager.Instance.LoadAsset<SkeletonDataAsset>("Hero/SpineRes/", skinCfg.SpineRes);
+ SkeletonGraphic skeletonGraphic = realGO.GetComponentInChildren<SkeletonGraphic>(true);
+
+ var skeletonDataAsset = ResManager.Instance.LoadAsset<SkeletonDataAsset>("Hero/SpineRes/", skinCfg.SpineRes);
+ if (skeletonDataAsset == null)
+ {
+ Debug.LogError("BattleObjectFactory.CreateBattleObject: skeletonDataAsset is null for " + skinCfg.SpineRes);
+ return null;
+ }
+
+ float finalScaleRate = modelScaleRate * teamHero.modelScale;
+
+ skeletonGraphic.skeletonDataAsset = skeletonDataAsset;
skeletonGraphic.Initialize(true);
realGO.name = battleObject.ObjID.ToString();
- realGO.transform.localScale = new Vector3((_Camp == BattleCamp.Red ? 1 : -1f) * modelScaleRate, modelScaleRate, modelScaleRate);
+ realGO.transform.localScale = new Vector3((_Camp == BattleCamp.Red ? 1 : -1f) * finalScaleRate, finalScaleRate, finalScaleRate);
battleObject.Init(realGO, teamHero, _Camp);
return battleObject;
}
diff --git a/Main/System/Battle/BattleTweenMgr.cs b/Main/System/Battle/BattleTweenMgr.cs
index ec5d21c..ce43c00 100644
--- a/Main/System/Battle/BattleTweenMgr.cs
+++ b/Main/System/Battle/BattleTweenMgr.cs
@@ -63,4 +63,16 @@
}
tweenList.Clear();
}
+
+ public void Release()
+ {
+ foreach (var tween in tweenList)
+ {
+ if (tween != null && !tween.IsComplete())
+ {
+ tween.Kill();
+ }
+ }
+ tweenList.Clear();
+ }
}
\ No newline at end of file
diff --git a/Main/System/Battle/Buff/BattleObjectBuffMgr.cs b/Main/System/Battle/Buff/BattleObjectBuffMgr.cs
index 7858db2..9ebda71 100644
--- a/Main/System/Battle/Buff/BattleObjectBuffMgr.cs
+++ b/Main/System/Battle/Buff/BattleObjectBuffMgr.cs
@@ -19,7 +19,7 @@
}
// 澧炲姞buff
- public void AddBuff(H0605_tagObjAddBuff vNetData)
+ public void AddBuff(HB428_tagSCBuffRefresh vNetData)
{
// BuffBase buffBase = BuffFactory.CreateBuff(vNetData, battleObject);
// if (null == buffBase)
@@ -28,10 +28,11 @@
// }
// buffBase.OnAdd();
+
}
// 鍒犻櫎buff
- public void RemoveBuff(H0606_tagObjDelBuff vNetData)
+ public void RemoveBuff(HB429_tagSCBuffDel vNetData)
{
// buffBase.OnRemove();
diff --git a/Main/System/Battle/Buff/BuffBase.cs b/Main/System/Battle/Buff/BuffBase.cs
index d032c89..a9b33e7 100644
--- a/Main/System/Battle/Buff/BuffBase.cs
+++ b/Main/System/Battle/Buff/BuffBase.cs
@@ -10,11 +10,11 @@
// public int DurationRound { get; protected set; } // 鎸佺画鍥炲悎鏁�
// public int ElapsedRound { get; protected set; } // 宸茬粡杩囩殑鍥炲悎鏁�
- protected H0605_tagObjAddBuff h0605_TagObjAddBuff;
+ protected HB428_tagSCBuffRefresh TagObjAddBuff;
- public BuffBase(H0605_tagObjAddBuff _h0605_TagObjAddBuff)
+ public BuffBase(HB428_tagSCBuffRefresh _TagObjAddBuff)
{
- h0605_TagObjAddBuff = _h0605_TagObjAddBuff;
+ TagObjAddBuff = _TagObjAddBuff;
// BuffId = buffId;
// Owner = owner;
// DurationRound = durationRound;
diff --git a/Main/System/Battle/Buff/BuffFactory.cs b/Main/System/Battle/Buff/BuffFactory.cs
index cda15e5..61b512f 100644
--- a/Main/System/Battle/Buff/BuffFactory.cs
+++ b/Main/System/Battle/Buff/BuffFactory.cs
@@ -5,7 +5,7 @@
/// </summary>
public static class BuffFactory
{
- public static BuffBase CreateBuff(H0605_tagObjAddBuff vNetData, BattleObject owner)
+ public static BuffBase CreateBuff(HB428_tagSCBuffRefresh vNetData, BattleObject owner)
{
// int buffId = vNetData.buffId;
// int durationRound = vNetData.durationRound;
diff --git a/Main/System/Battle/RecordPlayer/RecordPlayer.cs b/Main/System/Battle/RecordPlayer/RecordPlayer.cs
index 10b8da1..c5c9309 100644
--- a/Main/System/Battle/RecordPlayer/RecordPlayer.cs
+++ b/Main/System/Battle/RecordPlayer/RecordPlayer.cs
@@ -22,6 +22,7 @@
public void PlayRecord(RecordAction recordAction)
{
+ Debug.LogError("Enqueue record action " + recordAction.GetType());
recordActionQueue.Enqueue(recordAction);
}
@@ -29,7 +30,7 @@
{
for (int i = 0; i < recordActions.Count; i++)
{
- recordActionQueue.Enqueue(recordActions[i]);
+ PlayRecord(recordActions[i]);
}
}
@@ -59,6 +60,7 @@
if (recordActionQueue.Count > 0)
{
currentRecordAction = recordActionQueue.Dequeue();
+ Debug.LogError("play record action " + currentRecordAction.GetType());
}
}
}
@@ -79,4 +81,10 @@
currentRecordAction = null;
recordActionQueue.Clear();
}
+
+ public void Release()
+ {
+ currentRecordAction = null;
+ recordActionQueue.Clear();
+ }
}
\ No newline at end of file
diff --git a/Main/System/Battle/Skill/DirectlyDamageSkill.cs b/Main/System/Battle/Skill/DirectlyDamageSkill.cs
index f99118c..a81d548 100644
--- a/Main/System/Battle/Skill/DirectlyDamageSkill.cs
+++ b/Main/System/Battle/Skill/DirectlyDamageSkill.cs
@@ -9,7 +9,7 @@
protected SkillEffect skillEffect;
public DirectlyDamageSkill(BattleObject _caster, SkillConfig _skillCfg,
- H0604_tagUseSkillAttack _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
+ HB427_tagSCUseSkill _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
: base(_caster, _skillCfg, _vNetData, _packList, _battleField)
{
foreach (var pack in packList)
@@ -59,12 +59,12 @@
}
}
- protected override void OnHitTargets(int _hitIndex, List<H0604_tagUseSkillAttack.tagSkillHurtObj> hitList)
+ protected override void OnHitTargets(int _hitIndex, List<HB427_tagSCUseSkill.tagSCUseSkillHurt> hitList)
{
base.OnHitTargets(_hitIndex, hitList);
}
- protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref H0604_tagUseSkillAttack.tagSkillHurtObj hurt)
+ protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref HB427_tagSCUseSkill.tagSCUseSkillHurt hurt)
{
base.OnHitEachTarget(target, totalDamage, damageList, ref hurt);
}
diff --git a/Main/System/Battle/Skill/DirectlyHealSkill.cs b/Main/System/Battle/Skill/DirectlyHealSkill.cs
index 99c8877..f8f4325 100644
--- a/Main/System/Battle/Skill/DirectlyHealSkill.cs
+++ b/Main/System/Battle/Skill/DirectlyHealSkill.cs
@@ -9,7 +9,7 @@
protected SkillEffect skillEffect;
public DirectlyHealSkill(BattleObject _caster, SkillConfig _skillCfg,
- H0604_tagUseSkillAttack _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
+ HB427_tagSCUseSkill _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
: base(_caster, _skillCfg, _vNetData, _packList, _battleField)
{
foreach (var pack in packList)
@@ -59,12 +59,12 @@
}
}
- protected override void OnHitTargets(int _healIndex, List<H0604_tagUseSkillAttack.tagSkillHurtObj> healList)
+ protected override void OnHitTargets(int _healIndex, List<HB427_tagSCUseSkill.tagSCUseSkillHurt> healList)
{
base.OnHitTargets(_healIndex, healList);
}
- protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref H0604_tagUseSkillAttack.tagSkillHurtObj hurt)
+ protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref HB427_tagSCUseSkill.tagSCUseSkillHurt hurt)
{
base.OnHitEachTarget(target, totalDamage, damageList, ref hurt);
}
diff --git a/Main/System/Battle/Skill/RebornSkill.cs b/Main/System/Battle/Skill/RebornSkill.cs
index 2a876e0..985f131 100644
--- a/Main/System/Battle/Skill/RebornSkill.cs
+++ b/Main/System/Battle/Skill/RebornSkill.cs
@@ -9,7 +9,7 @@
protected SkillEffect skillEffect;
public RebornSkill(BattleObject _caster, SkillConfig _skillCfg,
- H0604_tagUseSkillAttack _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
+ HB427_tagSCUseSkill _vNetData, List<GameNetPackBasic> _packList, BattleField _battleField)
: base(_caster, _skillCfg, _vNetData, _packList, _battleField)
{
@@ -56,12 +56,12 @@
}
}
- protected override void OnHitTargets(int _hitIndex, List<H0604_tagUseSkillAttack.tagSkillHurtObj> hitList)
+ protected override void OnHitTargets(int _hitIndex, List<HB427_tagSCUseSkill.tagSCUseSkillHurt> hitList)
{
base.OnHitTargets(_hitIndex, hitList);
}
- protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref H0604_tagUseSkillAttack.tagSkillHurtObj hurt)
+ protected override void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref HB427_tagSCUseSkill.tagSCUseSkillHurt hurt)
{
base.OnHitEachTarget(target, totalDamage, damageList, ref hurt);
}
diff --git a/Main/System/Battle/Skill/SkillBase.cs b/Main/System/Battle/Skill/SkillBase.cs
index b8d127d..3921dc6 100644
--- a/Main/System/Battle/Skill/SkillBase.cs
+++ b/Main/System/Battle/Skill/SkillBase.cs
@@ -7,7 +7,7 @@
public class SkillBase
{
- protected H0604_tagUseSkillAttack tagUseSkillAttack;
+ protected HB427_tagSCUseSkill tagUseSkillAttack;
protected SkillConfig skillConfig;
@@ -27,13 +27,13 @@
protected List<GameNetPackBasic> packList;
- protected SkillBase otherSkill;
+ protected SkillRecordAction otherSkillAction;
protected List<H0704_tagRolePackRefresh> dropPackList = new List<H0704_tagRolePackRefresh>();
protected List<HB405_tagMCAddExp> expPackList = new List<HB405_tagMCAddExp>();
- public SkillBase(BattleObject _caster, SkillConfig _skillCfg, H0604_tagUseSkillAttack vNetData, List<GameNetPackBasic> _packList, BattleField _battleField = null)
+ public SkillBase(BattleObject _caster, SkillConfig _skillCfg, HB427_tagSCUseSkill vNetData, List<GameNetPackBasic> _packList, BattleField _battleField = null)
{
caster = _caster;
skillConfig = _skillCfg;
@@ -41,7 +41,7 @@
battleField = _battleField;
packList = _packList;
- }
+ }
public virtual void Run()
{
@@ -49,7 +49,21 @@
{
curFrame++;
}
+
+ if (otherSkillAction != null)
+ {
+ if (otherSkillAction.IsFinished())
+ {
+ otherSkillAction = null;
+ OnSkillFinished();
+ }
+ else
+ {
+ otherSkillAction.Run();
+ }
+ }
}
+
protected virtual void OnActiveSkillFrame()
{
@@ -96,10 +110,19 @@
break;
case SkillCastMode.Target:
// 鐩爣鏄晫鏂逛富鐩爣
- BattleObject mainTarget = battleField.battleObjMgr.GetBattleObject((int)tagUseSkillAttack.AttackID);
+ if (tagUseSkillAttack.HurtCount <= 0)
+ {
+ Debug.LogError("鎶�鑳芥敾鍑诲寘娌℃湁鐩爣 HurtCount <= 0");
+ OnSkillFinished();
+ return;
+ }
+
+ var mainHurt = tagUseSkillAttack.HurtList[0];
+
+ BattleObject mainTarget = battleField.battleObjMgr.GetBattleObject((int)mainHurt.ObjID);
if (mainTarget == null)
{
- Debug.LogError("鐩爣涓虹┖ mainTarget == null AttackID : " + tagUseSkillAttack.AttackID);
+ Debug.LogError("鐩爣涓虹┖ mainTarget == null ObjID : " + mainHurt.ObjID);
OnSkillFinished();
return;
}
@@ -209,11 +232,11 @@
}
// 鍛戒腑鐩爣鍚庣殑鍥炶皟 姝e父鏄互鍚勬妧鑳界殑鏂瑰紡鏉ュ鐞嗙殑
- protected virtual void OnHitTargets(int _hitIndex, List<H0604_tagUseSkillAttack.tagSkillHurtObj> hitList)
+ protected virtual void OnHitTargets(int _hitIndex, List<HB427_tagSCUseSkill.tagSCUseSkillHurt> hitList)
{
for (int i = 0; i < hitList.Count; i++)
{
- H0604_tagUseSkillAttack.tagSkillHurtObj hurt = hitList[i];
+ HB427_tagSCUseSkill.tagSCUseSkillHurt hurt = hitList[i];
BattleObject target = caster.battleField.battleObjMgr.GetBattleObject((int)hurt.ObjID);
if (target == null)
@@ -261,9 +284,9 @@
return fixedDamageList;
}
- protected virtual void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref H0604_tagUseSkillAttack.tagSkillHurtObj hurt)
+ protected virtual void OnHitEachTarget(BattleObject target, long totalDamage, List<long> damageList, ref HB427_tagSCUseSkill.tagSCUseSkillHurt hurt)
{
- target.Hurt(damageList, totalDamage, hurt.AttackType);
+ target.Hurt(damageList, totalDamage, hurt.AttackTypes);
// 鍑讳腑鐩爣鐨勬椂鍊�,涓嶇杩戞垬杩滅▼ 閮界‘璁や竴涓嬫槸鍚︽湁鐖嗙偢鐗规晥 鐒跺悗鎾斁
if (skillConfig.ExplosionEffectId > 0)
@@ -441,6 +464,24 @@
public void OnSkillFinished()
{
+ while (packList.Count > 0)
+ {
+ var pack = packList[0];
+ packList.RemoveAt(0);
+
+ if (pack is CustomHB426CombinePack)
+ {
+ var combinePack = pack as CustomHB426CombinePack;
+ if (combinePack.startTag.Tag.StartsWith("Skill_"))
+ {
+ otherSkillAction = combinePack.CreateSkillAction();
+ return;
+ }
+ }
+
+ PackageRegedit.Distribute(pack);
+ }
+
isFinished = true;
}
}
\ No newline at end of file
diff --git a/Main/System/Battle/Skill/SkillFactory.cs b/Main/System/Battle/Skill/SkillFactory.cs
index c1b284b..631ce82 100644
--- a/Main/System/Battle/Skill/SkillFactory.cs
+++ b/Main/System/Battle/Skill/SkillFactory.cs
@@ -41,9 +41,9 @@
- public static SkillBase CreateSkill(BattleObject _caster, H0604_tagUseSkillAttack vNetData, List<GameNetPackBasic> packList, BattleField battleField)
+ public static SkillBase CreateSkill(BattleObject _caster, HB427_tagSCUseSkill vNetData, List<GameNetPackBasic> packList, BattleField battleField)
{
- SkillConfig skillConfig = SkillConfig.Get(vNetData.SkillID);
+ SkillConfig skillConfig = SkillConfig.Get((int)vNetData.SkillID);
SkillBase skill = null;
switch (skillConfig.SkillType)
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/BezierBulletCurve.cs b/Main/System/Battle/SkillEffect/BulletCurve/BezierBulletCurve.cs
index 3a92a06..9de06db 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/BezierBulletCurve.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/BezierBulletCurve.cs
@@ -8,7 +8,7 @@
private Vector2 end;
private Vector2 control;
- public BezierBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer effectPlayer, RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ public BezierBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer effectPlayer, RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
: base(caster, skillConfig, effectPlayer, target, onHit) { }
public override void Reset()
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/BounceBulletCurve.cs b/Main/System/Battle/SkillEffect/BulletCurve/BounceBulletCurve.cs
index 772df81..7cd18f6 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/BounceBulletCurve.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/BounceBulletCurve.cs
@@ -7,7 +7,7 @@
/// </summary>
public class BounceBulletCurve : BulletCurve
{
- private List<H0604_tagUseSkillAttack.tagSkillHurtObj> hurtList;
+ private List<HB427_tagSCUseSkill.tagSCUseSkillHurt> hurtList;
private int curIndex = 0;
private Vector2 start;
private Vector2 end;
@@ -15,10 +15,10 @@
private float bounceElapsed = 0f;
public BounceBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer effectPlayer,
- RectTransform target, H0604_tagUseSkillAttack tagUseSkillAttack, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ RectTransform target, HB427_tagSCUseSkill tagUseSkillAttack, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
: base(caster, skillConfig, effectPlayer, target, onHit)
{
- this.hurtList = new List<H0604_tagUseSkillAttack.tagSkillHurtObj>(tagUseSkillAttack.HurtList);
+ this.hurtList = new List<HB427_tagSCUseSkill.tagSCUseSkillHurt>(tagUseSkillAttack.HurtList);
}
public override void Reset()
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/BulletCurve.cs b/Main/System/Battle/SkillEffect/BulletCurve/BulletCurve.cs
index b159e89..39a1089 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/BulletCurve.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/BulletCurve.cs
@@ -9,7 +9,7 @@
protected EffectPlayer bulletEffect;
protected RectTransform bulletTrans; // 瀛愬脊鐨凴ectTransform
protected RectTransform target;
- protected Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit;
+ protected Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit;
protected bool finished = false;
protected float duration = 0f;
@@ -17,7 +17,7 @@
public BulletCurve() { }
- public BulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer bulletEffect, RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ public BulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer bulletEffect, RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
{
this.caster = caster;
this.skillConfig = skillConfig;
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/BulletCurveFactory.cs b/Main/System/Battle/SkillEffect/BulletCurve/BulletCurveFactory.cs
index e0f6863..59e2841 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/BulletCurveFactory.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/BulletCurveFactory.cs
@@ -15,8 +15,8 @@
SkillConfig skillConfig,
EffectPlayer bulletEffect,
RectTransform target,
- H0604_tagUseSkillAttack tagUseSkillAttack,
- Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ HB427_tagSCUseSkill tagUseSkillAttack,
+ Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
{
switch (skillConfig.BulletPath)
{
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/PenetrateBulletCurve.cs b/Main/System/Battle/SkillEffect/BulletCurve/PenetrateBulletCurve.cs
index e34200b..fb884bd 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/PenetrateBulletCurve.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/PenetrateBulletCurve.cs
@@ -9,7 +9,7 @@
private Vector2 outPos; // 灞忓箷澶栧欢闀跨偣锛堟湰鍦板潗鏍囷級
private bool hitTriggered = false; // 鏄惁宸茶Е鍙憃nHit
- public PenetrateBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer effectPlayer, RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ public PenetrateBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer effectPlayer, RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
: base(caster, skillConfig, effectPlayer, target, onHit) { }
/// <summary>
diff --git a/Main/System/Battle/SkillEffect/BulletCurve/StraightBulletCurve.cs b/Main/System/Battle/SkillEffect/BulletCurve/StraightBulletCurve.cs
index b21c5bc..553ca14 100644
--- a/Main/System/Battle/SkillEffect/BulletCurve/StraightBulletCurve.cs
+++ b/Main/System/Battle/SkillEffect/BulletCurve/StraightBulletCurve.cs
@@ -7,7 +7,7 @@
private Vector2 start;
private Vector2 end;
- public StraightBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer bulletEffect, RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHit)
+ public StraightBulletCurve(BattleObject caster, SkillConfig skillConfig, EffectPlayer bulletEffect, RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHit)
: base(caster, skillConfig, bulletEffect, target, onHit) { }
public override void Reset()
diff --git a/Main/System/Battle/SkillEffect/BulletSkillEffect.cs b/Main/System/Battle/SkillEffect/BulletSkillEffect.cs
index 2981d31..c545416 100644
--- a/Main/System/Battle/SkillEffect/BulletSkillEffect.cs
+++ b/Main/System/Battle/SkillEffect/BulletSkillEffect.cs
@@ -13,7 +13,7 @@
protected List<BulletCurve> bulletCurves = new List<BulletCurve>();
- public BulletSkillEffect(SkillConfig _skillConfig, BattleObject _caster, H0604_tagUseSkillAttack _tagUseSkillAttack)
+ public BulletSkillEffect(SkillConfig _skillConfig, BattleObject _caster, HB427_tagSCUseSkill _tagUseSkillAttack)
: base(_skillConfig, _caster, _tagUseSkillAttack)
{
@@ -21,7 +21,7 @@
- public override void Play(Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ public override void Play(Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
// 寮瑰皠 鍙﹀鐨勫仛娉曚簡
if (skillConfig.effectType == SkillEffectType.Bullet && skillConfig.BulletPath == 4)
@@ -38,7 +38,7 @@
// 鏅�氱殑鍋氭硶
else
{
- Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHitFormation = (_hitIndex, _hurtList) =>
+ Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHitFormation = (_hitIndex, _hurtList) =>
{
_onHit?.Invoke(_hitIndex, tagUseSkillAttack.HurtList.ToList());
};
@@ -77,7 +77,7 @@
}
}
- protected void ShotToFormation(RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ protected void ShotToFormation(RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
EffectPlayer effectPlayer = caster.battleField.battleEffectMgr.PlayEffect(caster.ObjID, skillConfig.BulletEffectId, caster.effectNode);
@@ -111,7 +111,7 @@
}
- protected void ShotToTarget(BattleObject target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ protected void ShotToTarget(BattleObject target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
EffectPlayer effectPlayer = caster.battleField.battleEffectMgr.PlayEffect(caster.ObjID, skillConfig.BulletEffectId, caster.effectNode);
RectTransform effectTrans = effectPlayer.transform as RectTransform;
diff --git a/Main/System/Battle/SkillEffect/NormalSkillEffect.cs b/Main/System/Battle/SkillEffect/NormalSkillEffect.cs
index 616eef4..0e8d860 100644
--- a/Main/System/Battle/SkillEffect/NormalSkillEffect.cs
+++ b/Main/System/Battle/SkillEffect/NormalSkillEffect.cs
@@ -11,18 +11,18 @@
// protected BattleObject caster;
// protected List<BattleObject> targets; // 鐩爣鍒楄〃
- public NormalSkillEffect(SkillConfig _skillConfig, BattleObject _caster, H0604_tagUseSkillAttack _tagUseSkillAttack)
+ public NormalSkillEffect(SkillConfig _skillConfig, BattleObject _caster, HB427_tagSCUseSkill _tagUseSkillAttack)
: base(_skillConfig, _caster, _tagUseSkillAttack)
{
}
- public override void Play(Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ public override void Play(Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
// // 鐗规晥鐐稿紑鍦ㄩ樀瀹圭殑涓棿鐨勫洖璋�
- // Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> onHitLineUpCenter = (_hitIndex, _hurtList) =>
+ // Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> onHitLineUpCenter = (_hitIndex, _hurtList) =>
// {
// _onHit?.Invoke(_hitIndex, tagUseSkillAttack.HurtList.ToList());
// };
@@ -49,7 +49,7 @@
// continue;
// }
- // CastInTarget(target.heroGo.transform as RectTransform, (index, list) => _onHit(0, new List<H0604_tagUseSkillAttack.tagSkillHurtObj>() { hurt }));
+ // CastInTarget(target.heroGo.transform as RectTransform, (index, list) => _onHit(0, new List<HB427_tagSCUseSkill.tagSCUseSkillHurt>() { hurt }));
// }
// }
// else if (skillConfig.effectAnchor == SkillEffectAnchor.AlliesCenter)
@@ -66,7 +66,7 @@
// }
}
- protected void CastInTarget(RectTransform target, Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ protected void CastInTarget(RectTransform target, Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
// EffectPlayer effectPlayer = caster.battleField.battleEffectMgr.PlayEffect(caster.ObjID, skillConfig.EffectId, caster.effectNode);
diff --git a/Main/System/Battle/SkillEffect/SkillEffect.cs b/Main/System/Battle/SkillEffect/SkillEffect.cs
index 348f020..b6c41e1 100644
--- a/Main/System/Battle/SkillEffect/SkillEffect.cs
+++ b/Main/System/Battle/SkillEffect/SkillEffect.cs
@@ -6,9 +6,9 @@
{
protected SkillConfig skillConfig;
protected BattleObject caster;
- protected H0604_tagUseSkillAttack tagUseSkillAttack;// 鐩爣鍒楄〃
+ protected HB427_tagSCUseSkill tagUseSkillAttack;// 鐩爣鍒楄〃
- public SkillEffect(SkillConfig _skillConfig, BattleObject _caster, H0604_tagUseSkillAttack _tagUseSkillAttack)
+ public SkillEffect(SkillConfig _skillConfig, BattleObject _caster, HB427_tagSCUseSkill _tagUseSkillAttack)
{
skillConfig = _skillConfig;
caster = _caster;
@@ -16,7 +16,7 @@
}
//
- public virtual void Play(Action<int, List<H0604_tagUseSkillAttack.tagSkillHurtObj>> _onHit)
+ public virtual void Play(Action<int, List<HB427_tagSCUseSkill.tagSCUseSkillHurt>> _onHit)
{
}
diff --git a/Main/System/Battle/SkillEffect/SkillEffectFactory.cs b/Main/System/Battle/SkillEffect/SkillEffectFactory.cs
index bc4f710..7f6866d 100644
--- a/Main/System/Battle/SkillEffect/SkillEffectFactory.cs
+++ b/Main/System/Battle/SkillEffect/SkillEffectFactory.cs
@@ -4,7 +4,7 @@
public static class SkillEffectFactory
{
- public static SkillEffect CreateSkillEffect(BattleObject caster, SkillConfig skillConfig, H0604_tagUseSkillAttack tagUseSkillAttack)
+ public static SkillEffect CreateSkillEffect(BattleObject caster, SkillConfig skillConfig, HB427_tagSCUseSkill tagUseSkillAttack)
{
// switch (skillConfig.effectType)
// {
diff --git a/Main/System/HeroUI/HeroUIManager.cs b/Main/System/HeroUI/HeroUIManager.cs
index 57155c6..3af55ee 100644
--- a/Main/System/HeroUI/HeroUIManager.cs
+++ b/Main/System/HeroUI/HeroUIManager.cs
@@ -205,7 +205,7 @@
{
if (team.tempHeroes[i] == null)
continue;
- var country = (HeroCountry)team.tempHeroes[i].heroConfig.Country;
+ var country = (HeroCountry)team.tempHeroes[i].Country;
if (!heroCountryCount.ContainsKey(country))
{
diff --git a/Main/System/Message/RichTableEvent.cs b/Main/System/Message/RichTableEvent.cs
index 31e20ae..c298614 100644
--- a/Main/System/Message/RichTableEvent.cs
+++ b/Main/System/Message/RichTableEvent.cs
@@ -111,7 +111,7 @@
NPCConfig cfg = NPCConfig.Get(id);
if (cfg != null)
{
- return cfg.charName;
+ return cfg.NPCName;
}
}
}
diff --git a/Main/System/Team/TeamHero.cs b/Main/System/Team/TeamHero.cs
index 1c0c74a..52c1238 100644
--- a/Main/System/Team/TeamHero.cs
+++ b/Main/System/Team/TeamHero.cs
@@ -4,10 +4,13 @@
public partial class TeamHero
{
public int heroId;
- public HeroConfig heroConfig;
+
+ public HeroCountry Country;
public int SkinID;
public HeroSkinConfig skinConfig;
- public string guid;
+ public string guid;
+
+ public float modelScale = 1f;
public TeamBase teamBase
@@ -25,11 +28,28 @@
// 鏈嶅姟鍣ㄦ潵鐨勬瀯閫�
public TeamHero(HB424_tagSCTurnFightInit.tagSCTurnFightObj fightObj, TeamBase _teamBase)
{
+ // 鍒ゆ柇涓�涓嬫槸npc杩樻槸鐜╁
heroId = (int)fightObj.HeroID;
- heroConfig = HeroConfig.Get(heroId);
- SkinID = (int)fightObj.SkinID;
- skinConfig = HeroSkinConfig.Get(SkinID);
+ if (fightObj.NPCID > 0)
+ {
+ //璧癗PC鐨勯�昏緫
+ NPCConfig npcConfig = NPCConfig.Get((int)fightObj.NPCID);
+ Country = (HeroCountry)npcConfig.Country;
+ SkinID = npcConfig.SkinID;
+ modelScale = npcConfig.ModelScale;
+ }
+ else
+ {
+ //璧扮帺瀹堕�昏緫
+ var heroConfig = HeroConfig.Get(heroId);
+ Country = (HeroCountry)heroConfig.Country;
+ SkinID = (int)fightObj.SkinID;
+ modelScale = 1f;
+ }
+
+
+ skinConfig = HeroSkinConfig.Get(SkinID);
teamBase = _teamBase;
ObjID = (int)fightObj.ObjID;
@@ -55,7 +75,6 @@
public TeamHero(HeroInfo heroInfo, int posNum, TeamBase _teamBase)
{
heroId = heroInfo.itemHero.config.ID;
- heroConfig = HeroConfig.Get(heroId);
SkinID = heroInfo.SkinID;
skinConfig = heroInfo.skinConfig;
--
Gitblit v1.8.0