LANCommander/LANCommander.Launcher.Data/Models/Game.cs
Pat Hartl 9ba9887eb1 Rename project files, namespaces, artifacts
Client has been renamed to launcher, and thus namespaces and artifact names had to change. The server project has also had some artifacts renamed in order to create a more clear separation of builds. This will break auto-updates before v0.9.0.
2024-08-04 17:53:19 -05:00

51 lines
2.4 KiB
C#

using LANCommander.Launcher.Data.Enums;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace LANCommander.Launcher.Data.Models
{
[Table("Games")]
public class Game : BaseModel
{
public long? IGDBId { get; set; }
public string Title { get; set; }
[Display(Name = "Sort Title")]
public string? SortTitle { get; set; }
[Display(Name = "Directory Name")]
public string? Description { get; set; }
public string? Notes { get; set; }
public bool Installed { get; set; }
public string? InstallDirectory { get; set; }
public string? InstalledVersion { get; set; }
public DateTime? InstalledOn { get; set; }
public string? LatestVersion { get; set; }
[Display(Name = "Released On")]
public DateTime? ReleasedOn { get; set; }
public GameType Type { get; set; }
public Guid? BaseGameId { get; set; }
[ForeignKey(nameof(BaseGameId))]
public virtual Game? BaseGame { get; set; }
public bool Singleplayer { get; set; } = false;
public Guid? EngineId { get; set; }
[ForeignKey(nameof(EngineId))]
public virtual Engine Engine { get; set; }
public virtual ICollection<MultiplayerMode>? MultiplayerModes { get; set; } = new List<MultiplayerMode>();
public virtual ICollection<Genre>? Genres { get; set; } = new List<Genre>();
public virtual ICollection<Tag>? Tags { get; set; } = new List<Tag>();
public virtual ICollection<Category>? Categories { get; set; } = new List<Category>();
public virtual ICollection<Company>? Publishers { get; set; } = new List<Company>();
public virtual ICollection<Company>? Developers { get; set; } = new List<Company>();
public virtual ICollection<Platform>? Platforms { get; set; } = new List<Platform>();
public virtual ICollection<Redistributable>? Redistributables { get; set; } = new List<Redistributable>();
public virtual ICollection<Media>? Media { get; set; } = new List<Media>();
public virtual ICollection<Collection> Collections { get; set; } = new List<Collection>();
public virtual ICollection<Game> DependentGames { get; set; } = new List<Game>();
public virtual ICollection<PlaySession> PlaySessions { get; set; } = new List<PlaySession>();
}
}