mirror of
https://github.com/rafi1212122/PemukulPaku
synced 2025-12-12 22:24:34 +01:00
yes command yesyes
This commit is contained in:
20
Program.cs
20
Program.cs
@@ -25,25 +25,7 @@ namespace PemukulPaku
|
||||
|
||||
Player Player = new(User.FromName("test"));
|
||||
|
||||
while (true)
|
||||
{
|
||||
string? line = Console.ReadLine();
|
||||
|
||||
if (!string.IsNullOrEmpty(line))
|
||||
{
|
||||
foreach (Command cmd in CommandFactory.Commands)
|
||||
{
|
||||
if (line.StartsWith(cmd.Name.ToLower()))
|
||||
{
|
||||
List<string> args = line.Split(' ').ToList();
|
||||
args.RemoveAt(0);
|
||||
|
||||
cmd.Run(null, args.ToArray());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
ReadLine.GetInstance().Start();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user