Ready for the first beta release. #105

Merged
That-One-Nerd merged 41 commits from main-canary into main 2023-05-18 13:05:42 -04:00
2 changed files with 16 additions and 4 deletions
Showing only changes of commit 7854a576a7 - Show all commits

View File

@ -3,10 +3,12 @@
public class Mod
{
public string Name { get; set; }
public string RootDirectory { get; set; }
private Mod()
{
Name = string.Empty;
RootDirectory = string.Empty;
}
public static Mod? ReadDirectory(string dir)
@ -15,7 +17,8 @@ public class Mod
Mod mod = new()
{
Name = dir.Split("\\").Last()
Name = dir.Split("\\").Last(),
RootDirectory = dir
};
return mod;

View File

@ -139,9 +139,18 @@ public class Shell
public string ReadLine()
{
Write($"\n{WorkingDirectory}", ConsoleColor.DarkGreen, false);
if (ActiveGame is not null) Write($" {ActiveGame}", ConsoleColor.DarkYellow, false);
Write("\n", newLine: false);
if (ActiveMod is not null) Write($"{ActiveMod} ", ConsoleColor.Magenta, false);
if (ActiveMod is not null)
{
That-One-Nerd commented 2023-05-18 10:34:54 -04:00 (Migrated from github.com)
Review

I forgot to sync the shell's active game with the mod's base game.

I forgot to sync the shell's active game with the mod's base game.
That-One-Nerd commented 2023-05-18 11:11:23 -04:00 (Migrated from github.com)
Review

No longer an issue.

No longer an issue.
string directory = Path.GetRelativePath(ActiveMod.RootDirectory, WorkingDirectory);
if (directory == ".") directory = string.Empty;
Write($"~\\{directory}", ConsoleColor.DarkGreen, false);
}
else Write($"{WorkingDirectory}", ConsoleColor.DarkGreen, false);
if (ActiveGame is not null) Write($" ({ActiveGame})", ConsoleColor.DarkYellow, false);
Write(null);
Write($" {Name}", ConsoleColor.DarkCyan, false);