Documentation index for AI agents (llms.txt) A Markdown version of every page is available: request the page's source under /docs/, follow the "alternate" link in this page's head, or start from /llms.txt.
Game Creator 3 logo Dialogue

Stop All Dialogues#

Game Creator / Dialogue / Stop All Dialogues

Description#

Stops all playing Dialogue components

Code#

using System;
using UnityEngine;
using VisualScript.Icons;
using VisualScript.Runtime;

namespace GameCreator.Runtime.Dialogue
{
    [Title("Stop All Dialogues")]
    [Image(typeof(IconDialogue), ColorTheme.Type.Blue, typeof(BadgeCross))]

    [Description("Stops all playing Dialogue components")]
    [Category("Game Creator/Dialogue/Stop All Dialogues")]

    [Keywords("Dialogue", "Script", "Cancel", "End", "Finish", "All", "Multiple")]

    [Serializable]
    public class InstructionDialogueStopAll : Instruction
    {
        protected override string GetTitle(GameObject source) => "Stop All Dialogues";

        protected override Awaitable Run(Args args)
        {
            foreach (Dialogue dialogue in Dialogue.Active)
            {
                if (dialogue == null) continue;
                dialogue.Cancel();
            }

            return Done;
        }
    }
}
Game Creator 3 logoGame Creator 3 © Catsoft Works 2026. All rights reserved.