|
@@ -15,6 +15,8 @@ namespace GFGGame
|
|
|
private UI_CompArrow _arrow;
|
|
|
private GameObject _sceneObject;
|
|
|
private GameObject _scenePrefab;
|
|
|
+ private GameObject _npcHead;
|
|
|
+ private GoWrapper _npcWrapper;
|
|
|
private GTextField _wordTextField;
|
|
|
//žçÇéÍęłÉťŘľ÷
|
|
|
private OnCompleteStoryDialogCall _onCompleteStoryDialogCall;
|
|
@@ -46,7 +48,10 @@ namespace GFGGame
|
|
|
_wordTextField = null;
|
|
|
_arrow = null;
|
|
|
_isShowLetters = false;
|
|
|
+ SceneController.DestroyObjectFromView(_npcHead);
|
|
|
+
|
|
|
Timers.inst.Remove(UpdateLetters);
|
|
|
+
|
|
|
}
|
|
|
|
|
|
protected override void Init()
|
|
@@ -310,6 +315,7 @@ namespace GFGGame
|
|
|
string words = content;
|
|
|
string roleName = storyDialogCfg.name;
|
|
|
string headRes = storyDialogCfg.head;
|
|
|
+ string headAniRes = storyDialogCfg.headAni;
|
|
|
if (roleName == "self")
|
|
|
{
|
|
|
roleName = RoleDataManager.roleName;
|
|
@@ -319,12 +325,29 @@ namespace GFGGame
|
|
|
{
|
|
|
_dialogListLookBack.Add("[color=#FDA2B1]" + roleName + "[/color]");
|
|
|
}
|
|
|
- if (!string.IsNullOrEmpty(headRes))
|
|
|
+ if (!string.IsNullOrEmpty(headAniRes))
|
|
|
{
|
|
|
_ui.m_dialogText.target.visible = false;
|
|
|
_ui.m_dialogName.target.visible = false;
|
|
|
_ui.m_dialogHead.target.visible = true;
|
|
|
_ui.m_dialogHead.m_txtName.text = roleName;
|
|
|
+ _ui.m_dialogHead.m_comphead.m_head.visible = false;
|
|
|
+ _ui.m_dialogHead.m_comphead.m_holder.visible = true;
|
|
|
+ string resPath = ResPathUtil.GetViewEffectPath("ui_nzbq", headAniRes);
|
|
|
+ SceneController.AddObjectToView(_npcHead, _npcWrapper, _ui.m_dialogHead.m_comphead.m_holder, resPath, out _npcHead, out _npcWrapper);
|
|
|
+ _npcHead.transform.localScale = new Vector3(-100, 100, 100);
|
|
|
+ _wordTextField = _ui.m_dialogHead.m_txtContent;
|
|
|
+ _arrow = _ui.m_dialogHead.m_iconNext;
|
|
|
+ }
|
|
|
+ else if (!string.IsNullOrEmpty(headRes))
|
|
|
+ {
|
|
|
+ _ui.m_dialogText.target.visible = false;
|
|
|
+ _ui.m_dialogName.target.visible = false;
|
|
|
+ _ui.m_dialogHead.target.visible = true;
|
|
|
+ _ui.m_dialogHead.m_txtName.text = roleName;
|
|
|
+ _ui.m_dialogHead.m_comphead.m_head.visible = true;
|
|
|
+ _ui.m_dialogHead.m_comphead.m_holder.visible = false;
|
|
|
+
|
|
|
_ui.m_dialogHead.m_comphead.m_head.url = ResPathUtil.GetNpcHeadPath(headRes);
|
|
|
_wordTextField = _ui.m_dialogHead.m_txtContent;
|
|
|
_arrow = _ui.m_dialogHead.m_iconNext;
|