From 6d2eb0fafc15c7defc18ed7d5038dbe3512fc64c Mon Sep 17 00:00:00 2001
From: client_Hale <339726288@qq.com>
Date: 星期二, 16 十月 2018 17:22:55 +0800
Subject: [PATCH] 3732 子 【优化】Npc读取待机动作2号 / 【前端】场景Npc读取待机动作2号
---
Fight/Actor/State/SMB/Idle_0.cs | 13 +++++++++++++
System/GeneralConfig/GeneralConfig.cs | 2 ++
2 files changed, 15 insertions(+), 0 deletions(-)
diff --git a/Fight/Actor/State/SMB/Idle_0.cs b/Fight/Actor/State/SMB/Idle_0.cs
index 104a233..8c36835 100644
--- a/Fight/Actor/State/SMB/Idle_0.cs
+++ b/Fight/Actor/State/SMB/Idle_0.cs
@@ -23,6 +23,19 @@
m_LastDanceTime = Time.time;
}
}
+ else
+ {
+
+ GA_NpcFunc _funcNpc = owner as GA_NpcFunc;
+ if (_funcNpc != null && _funcNpc.NpcConfig.NPCType == 0)
+ {
+ if (Time.time - m_LastDanceTime > GeneralConfig.Instance.FuncNpcDanceInterval)
+ {
+ _funcNpc.Play(GAStaticDefine.State_Dance);
+ m_LastDanceTime = Time.time;
+ }
+ }
+ }
}
protected override void OnExit(GActor owner, Animator animator, AnimatorStateInfo stateInfo, int layerIndex)
diff --git a/System/GeneralConfig/GeneralConfig.cs b/System/GeneralConfig/GeneralConfig.cs
index 92f3595..b5e5184 100644
--- a/System/GeneralConfig/GeneralConfig.cs
+++ b/System/GeneralConfig/GeneralConfig.cs
@@ -38,6 +38,7 @@
public List<int> SpecialNpcIDs { get; private set; }
public Dictionary<int, int> wingEquipLimits { get; private set; }
public float PetDanceInterval { get; private set; }
+ public float FuncNpcDanceInterval { get; private set; }
public float audioScaleWhenFullScreenOn { get; private set; }
public int ruinsTranscriptMapId { get; private set; }
public List<int> GuardianPickUpID { get; private set; }
@@ -179,6 +180,7 @@
FarawayNpcDist = GetFloat("ConversationDistanc");
SpecialNpcIDs = new List<int>(GetIntArray("SpecialCollectNpcs", 1));
PetDanceInterval = GetInt("PetDanceInterval") * Constants.F_GAMMA;
+ FuncNpcDanceInterval = GetInt("PetDanceInterval",2) * Constants.F_GAMMA;
ruinsTranscriptMapId = GetInt("SpRewardMapID");
EarlierGetTreasure = new List<int>(GetIntArray("EarlierGetTreasure"));
BossSound = GetInt("BossSound");
--
Gitblit v1.8.0