Browse Source

【优化】MMO-20057:填坑代码控制技能cd,段数的法师1技能问题

meijun 3 years ago
parent
commit
fc1849b7e4

+ 5 - 2
Common/CommonAI/Zone/Instance/InstanceUnit.StateMachine.cs

@@ -1046,7 +1046,7 @@ namespace CommonAI.Zone.Instance
 
                 if (action_queue != null && action_queue.Count > 0)
                 {
-                    bool isNeedNotifyClient = (this.current_action != null && (this.current_action.SigleActionType == ActionEnum.IsAutoNext
+					bool isNeedNotifyClient = (this.current_action != null && (this.current_action.SigleActionType == ActionEnum.IsAutoNext
                         || this.current_action.SigleActionType == ActionEnum.chargeAtk));
                     //bool perChargeAtk = (this.current_action != null && this.current_action.SigleActionType == ActionEnum.chargeAtk);
                     this.current_action = action_queue.Dequeue();
@@ -1103,7 +1103,10 @@ namespace CommonAI.Zone.Instance
 							}
 						}
 
-						this.PushLaunchSkillEvent(skill.ActionIndex);
+						if(this.current_action.SigleActionType != ActionEnum.IsAutoNext)
+						{
+							this.PushLaunchSkillEvent(skill.ActionIndex);
+						}						
                     }
 
                     if (IsNoneBlock)

+ 8 - 3
Common/CommonAI/Zone/Instance/InstanceUnit.Status.cs

@@ -895,7 +895,7 @@ namespace CommonAI.Zone.Instance
 			private byte mMaxMutilStep = 0;
 
 			//代码逻辑控制cd
-			private bool mCodeControlCD;
+			private bool mCodeControl_HasNext;
             
             /// <summary>
             /// 当前技能是否放完
@@ -933,7 +933,7 @@ namespace CommonAI.Zone.Instance
 
 			public bool IsCodeConttrolCD()
 			{
-				return this.mCodeControlCD;
+				return this.mCodeControl_HasNext;
 			}
 
             /// <summary>
@@ -1254,10 +1254,15 @@ namespace CommonAI.Zone.Instance
 
 			public void LogicToCD()
 			{
-				this.mCodeControlCD = true;
+				this.mCodeControl_HasNext = true;
 				this.StartCD();
 			}
 
+			public void SetCodeControlNext()
+			{
+				this.mCodeControl_HasNext = false;
+			}
+
 			public void ForceIntoCD()
 			{
 				this.is_in_mutil_time = false;

+ 1 - 0
XmdsVSPlugins/XmdsCommonSkill/Plugin/Skills/Magic/Magic_310100.cs

@@ -105,6 +105,7 @@ namespace XmdsCommonSkill.Plugin.Skills.Magic
 				}
 				else
 				{
+					state.SetCodeControlNext();
 					state.IsInMutilTime = true;
 					this.mIsHasNextValidTime = CommonLang.CUtils.localTimeMS + state.Data.SingleActionCoolDownMS;