|
@@ -142,7 +142,6 @@ namespace GFGGame
|
|
|
if (_storyStartID == MainStoryDataManager.priorId)
|
|
|
{
|
|
|
_ui.m_c1.selectedIndex = 1;
|
|
|
- // _ui.m_btnAutoPlay.selected = true;
|
|
|
OnClickBtnAutoPlay();
|
|
|
_speedAutoPlay = 1;
|
|
|
FightDataManager.Instance.dialogSpeed = _speedAutoPlay;
|
|
@@ -179,11 +178,8 @@ namespace GFGGame
|
|
|
|
|
|
private void OnClickBtnBack()
|
|
|
{
|
|
|
-
|
|
|
+ //Hide();
|
|
|
ViewManager.Show<StoryChapterView>(MainStoryDataManager.currentChapterCfgId, ViewManager.GetGoBackDatas(typeof(StoryChapterView).FullName), true);
|
|
|
- this.Hide();
|
|
|
- //ViewManager.GoBackFrom(typeof(StoryDialogView).FullName);
|
|
|
- // Over(false);
|
|
|
}
|
|
|
|
|
|
private void OnClickBtnNext()
|
|
@@ -426,6 +422,11 @@ namespace GFGGame
|
|
|
string roleName = storyDialogCfg.name;
|
|
|
string headRes = storyDialogCfg.head;
|
|
|
string headAniRes = storyDialogCfg.headAni;
|
|
|
+
|
|
|
+ VoiceManager.Instance.StopVoice();
|
|
|
+ // 如果配置了语音,读取语音
|
|
|
+ VoiceManager.Instance.LoadRes(ResPathUtil.GetCardSoundPath("111111111"));
|
|
|
+
|
|
|
if (roleName == "self")
|
|
|
{
|
|
|
roleName = RoleDataManager.roleName;
|
|
@@ -468,7 +469,6 @@ namespace GFGGame
|
|
|
{
|
|
|
_dressUpObjUI.dressUpObj.CancelAction(true);
|
|
|
}
|
|
|
- //_dressUpObjUI.dressUpObj.PutOnDressUpData(_dressUpObjUI.dressUpObj.DressUpDataClone(), new int[] { ConstDressUpItemType.SHOU_CHI_WU });
|
|
|
}
|
|
|
if (headAniCfg != null && headAniCfg.faceId > 0)
|
|
|
{
|
|
@@ -550,6 +550,7 @@ namespace GFGGame
|
|
|
}
|
|
|
_wordList = Regex.Split(words, "&&");
|
|
|
_wordIndex = 0;
|
|
|
+
|
|
|
_typingEffect = new TypingFadeEffectPro(_wordTextField);
|
|
|
_typingEffect.typeFinishedAction = ShowCurrentWords;
|
|
|
|
|
@@ -592,7 +593,8 @@ namespace GFGGame
|
|
|
_wordIndex++;
|
|
|
if (_autoPlay)
|
|
|
{
|
|
|
- Timers.inst.Add(GameConst.NEXT_WORDS_INTERVAL_MAX / _speedAutoPlay, 1, ShowNextWords);
|
|
|
+ int interval = (int)Mathf.Max(VoiceManager.Instance.GetClipLength(), GameConst.NEXT_WORDS_INTERVAL_MAX / _speedAutoPlay);
|
|
|
+ Timers.inst.Add(interval, 1, ShowNextWords);
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -638,10 +640,16 @@ namespace GFGGame
|
|
|
StartTyping();
|
|
|
}
|
|
|
|
|
|
+ /// <summary>
|
|
|
+ /// 开启打字机显示
|
|
|
+ /// </summary>
|
|
|
private void StartTyping()
|
|
|
{
|
|
|
_typingEffect.SetSpeed(_speedAutoPlay);
|
|
|
_typingEffect.Start();
|
|
|
+
|
|
|
+ // 如果配置了语音,则播放语音
|
|
|
+ VoiceManager.Instance.PlayVoice();
|
|
|
}
|
|
|
|
|
|
private void StopTyping()
|