mirror of
https://github.com/Stone-Red-Code/RemSox.git
synced 2026-09-06 23:41:33 +02:00
Add printLine support for commands and implement basic UI controls rendering
This commit is contained in:
@@ -8,13 +8,13 @@ public sealed class HelpCommand : ICommand
|
||||
|
||||
public string Description => "Show this help message";
|
||||
|
||||
public void Execute(string? arguments)
|
||||
public void Execute(string? arguments, Action<string> printLine)
|
||||
{
|
||||
Console.WriteLine("Available commands:");
|
||||
printLine("Available commands:");
|
||||
|
||||
foreach (ICommand command in CommandManager.GetCommands())
|
||||
{
|
||||
Console.WriteLine($" {command.Name,-12} - {command.Description}");
|
||||
printLine($" {command.Name,-12} - {command.Description}");
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user