|
|
|
@ -8,8 +8,6 @@ namespace Fungus.Script
|
|
|
|
|
|
|
|
|
|
public class SayDialog : Dialog |
|
|
|
|
{ |
|
|
|
|
public Image continueImage; |
|
|
|
|
|
|
|
|
|
public void Say(string text, Action onComplete) |
|
|
|
|
{ |
|
|
|
|
Clear(); |
|
|
|
@ -20,8 +18,7 @@ namespace Fungus.Script
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
StartCoroutine(WriteText(text, delegate { |
|
|
|
|
ShowContinueIcon(true); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
StartCoroutine(WaitForInput(delegate { |
|
|
|
|
Clear(); |
|
|
|
|
|
|
|
|
@ -37,15 +34,6 @@ namespace Fungus.Script
|
|
|
|
|
protected override void Clear() |
|
|
|
|
{ |
|
|
|
|
base.Clear(); |
|
|
|
|
ShowContinueIcon(false); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
void ShowContinueIcon(bool visible) |
|
|
|
|
{ |
|
|
|
|
if (continueImage != null) |
|
|
|
|
{ |
|
|
|
|
continueImage.enabled = visible; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
IEnumerator WaitForInput(Action onInput) |
|
|
|
|