using System.ComponentModel.DataAnnotations; using System.Globalization; namespace StarsAssistant.Model; public class Game (string gamePath, string baseName) { /// /// The base path in which all game files reside. /// public string GamePath { get; private set; } = gamePath; /// /// The base name without extensions of your game, inside the GamePath folder. /// All dependant files are resolved using this name. /// public string BaseName { get; private set; } = baseName; /// /// The number of the player, for example identifying the pxx planet file. /// public int PlayerId { get; private set; } /// /// Combine into the DatabaseName /// public string DatabaseName => Path.Combine(GamePath, $"{BaseName}.sqlite"); /// /// Search for Planet files using this pattern, will give you all pxx files. /// public string PlanetFileSearchPattern => Path.Combine(GamePath, $"{BaseName}.p*"); }