5dplomacy/MultiversalDiplomacy/Script/IScriptHandler.cs

19 lines
578 B
C#

namespace MultiversalDiplomacy.Script;
/// <summary>
/// A handler that interprets and executes 5dp script commands. Script handlers may create additional script handlers
/// and delegate handling to them, allowing a sort of recursive parsing of script commands.
/// </summary>
public interface IScriptHandler
{
/// <summary>
/// When used interactively, the prompt that should be displayed.
/// </summary>
public string Prompt { get; }
/// <summary>
/// Process a line of input.
/// </summary>
public ScriptResult HandleInput(string input);
}