@ -66,6 +66,11 @@ namespace Fungus
}
public override void OnStopExecuting()
{
CameraController.GetInstance().StopAllCoroutines();
public override string GetSummary()
if (targetView == null)
@ -46,6 +46,11 @@ namespace Fungus
@ -240,6 +240,7 @@ namespace Fungus
// Tell the executing command to stop immediately
if (activeCommand != null)
activeCommand.isExecuting = false;
activeCommand.OnStopExecuting();
@ -82,9 +82,13 @@ namespace Fungus
public virtual void Continue()
// This is a noop if the Block has already been stopped
if (isExecuting)
Continue(commandIndex + 1);
public virtual void Continue(int nextCommandIndex)
@ -42,6 +42,17 @@ namespace Fungus
public ColorData setColor = new ColorData(Color.white);
protected Writer GetWriter()
Writer writer = textObject.GetComponent<Writer>();
if (writer == null)
writer = textObject.AddComponent<Writer>() as Writer;
return writer;
public override void OnEnter()
if (textObject == null)
@ -50,7 +61,7 @@ namespace Fungus
return;
Writer writer = FindWriter(textObject);
Writer writer = GetWriter();
Continue();
@ -101,15 +112,9 @@ namespace Fungus
return new Color32(235, 191, 217, 255);
protected Writer FindWriter(GameObject textObject)
GetWriter().Stop();
//
@ -268,9 +268,12 @@ namespace Fungus
public virtual void Stop()
if (isWriting || isWaitingForInput)
exitFlag = true;
public virtual void Write(string content, bool clear, bool waitForInput, AudioClip audioClip, Action onComplete)