|
|
@@ -17,6 +17,7 @@ namespace Fort23.Mono
|
|
|
[UIBinding(prefab = "DialoguePanel")]
|
|
|
public partial class DialoguePanel : UIPanel
|
|
|
{
|
|
|
+ private bool isShowAnima;
|
|
|
private int[] dialogueMessaga;
|
|
|
private ShowDialogueEventData.MessageShowType messageShowType;
|
|
|
private Action<int?> finish;
|
|
|
@@ -51,14 +52,14 @@ namespace Fort23.Mono
|
|
|
{
|
|
|
DialoguePanel dialoguePanel = await UIManager.Instance.LoadAndOpenPanel<DialoguePanel>(null, UILayer.Top,
|
|
|
uiData: new object[] { CurrentEventList, id, icon, messageShowType, finish, isShowAnima });
|
|
|
- if (isShowAnima)
|
|
|
- {
|
|
|
- dialoguePanel.DialgueType1Anim.Play("DialgueType1open");
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- dialoguePanel.DialgueType1Anim.Play("DialgueType1idle1");
|
|
|
- }
|
|
|
+ // if (isShowAnima)
|
|
|
+ // {
|
|
|
+ // dialoguePanel.DialgueType1Anim.Play("DialgueType1open");
|
|
|
+ // }
|
|
|
+ // else
|
|
|
+ // {
|
|
|
+ // dialoguePanel.DialgueType1Anim.Play("DialgueType1idle1");
|
|
|
+ // }
|
|
|
|
|
|
// dialoguePanel.ShowPanel(CurrentEventList, id, icon, messageShowType, finish);
|
|
|
}
|
|
|
@@ -72,10 +73,20 @@ namespace Fort23.Mono
|
|
|
dialoguePanel.ShowPanel(LanID, icon, messageShowType, finish);
|
|
|
}
|
|
|
|
|
|
- public override CTask Show()
|
|
|
+ public async override CTask Show()
|
|
|
{
|
|
|
EventManager.Instance.Dispatch(CustomEventType.DialoguePanelOpen, null);
|
|
|
- return base.Show();
|
|
|
+
|
|
|
+
|
|
|
+ base.Show();
|
|
|
+ if (isShowAnima)
|
|
|
+ {
|
|
|
+ DialgueType1Anim.Play("DialgueType1open");
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ DialgueType1Anim.Play("DialgueType1idle1");
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
public async override CTask<bool> AsyncInit(object[] uiData)
|
|
|
@@ -149,14 +160,8 @@ namespace Fort23.Mono
|
|
|
ShowDialogueEventData.MessageShowType messageShowType,
|
|
|
Action<int?> finish, bool isShowAnima)
|
|
|
{
|
|
|
- if (isShowAnima)
|
|
|
- {
|
|
|
- DialgueType1Anim.Play("DialgueType1open");
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- DialgueType1Anim.Play("DialgueType1idle1");
|
|
|
- }
|
|
|
+ this.isShowAnima = isShowAnima;
|
|
|
+
|
|
|
|
|
|
this.CurrentEventList = CurrentEventList;
|
|
|
eventConditionConfig = ConfigComponent.Instance.Get<EventLinkConfig>(id);
|