huge commit for advanced stats feature.

broke data out into its own library.
may be breaking changes with existing plugins
This commit is contained in:
RaidMax
2021-03-22 11:09:25 -05:00
parent db2e1deb2f
commit c5375b661b
505 changed files with 13671 additions and 3271 deletions

View File

@ -0,0 +1,21 @@
using System.ComponentModel.DataAnnotations;
using Data.Abstractions;
using Stats.Models;
namespace Data.Models.Client.Stats.Reference
{
public class EFHitLocation : AuditFields, IUniqueId
{
[Key]
public int HitLocationId { get; set; }
[Required]
public string Name { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
public long Id => HitLocationId;
public string Value => Name;
}
}

View File

@ -0,0 +1,21 @@
using System.ComponentModel.DataAnnotations;
using Data.Abstractions;
using Stats.Models;
namespace Data.Models.Client.Stats.Reference
{
public class EFMap : AuditFields, IUniqueId
{
[Key]
public int MapId { get; set; }
[Required]
public string Name { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
public long Id => MapId;
public string Value => Name;
}
}

View File

@ -0,0 +1,21 @@
using System.ComponentModel.DataAnnotations;
using Data.Abstractions;
using Stats.Models;
namespace Data.Models.Client.Stats.Reference
{
public class EFMeansOfDeath: AuditFields, IUniqueId
{
[Key]
public int MeansOfDeathId { get; set; }
[Required]
public string Name { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
public long Id => MeansOfDeathId;
public string Value => Name;
}
}

View File

@ -0,0 +1,21 @@
using System.ComponentModel.DataAnnotations;
using Data.Abstractions;
using Stats.Models;
namespace Data.Models.Client.Stats.Reference
{
public class EFWeapon : AuditFields, IUniqueId
{
[Key]
public int WeaponId { get; set; }
[Required]
public string Name { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
public long Id => WeaponId;
public string Value => Name;
}
}

View File

@ -0,0 +1,21 @@
using System.ComponentModel.DataAnnotations;
using Data.Abstractions;
using Stats.Models;
namespace Data.Models.Client.Stats.Reference
{
public class EFWeaponAttachment : AuditFields, IUniqueId
{
[Key]
public int WeaponAttachmentId { get; set; }
[Required]
public string Name { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
public long Id => WeaponAttachmentId;
public string Value => Name;
}
}

View File

@ -0,0 +1,35 @@
using Data.Abstractions;
using Stats.Models;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
namespace Data.Models.Client.Stats.Reference
{
public class EFWeaponAttachmentCombo : AuditFields, IUniqueId
{
[Key]
public int WeaponAttachmentComboId { get; set; }
[Required]
public Models.Reference.Game Game { get; set; }
[Required]
public int Attachment1Id { get; set; }
[ForeignKey(nameof(Attachment1Id))]
public virtual EFWeaponAttachment Attachment1 { get; set; }
public int? Attachment2Id { get; set; }
[ForeignKey(nameof(Attachment2Id))]
public virtual EFWeaponAttachment Attachment2 { get; set; }
public int? Attachment3Id { get; set; }
[ForeignKey(nameof(Attachment3Id))]
public virtual EFWeaponAttachment Attachment3 { get; set; }
public long Id => WeaponAttachmentComboId;
public string Value => $"{Attachment1Id}{Attachment2Id}{Attachment3Id}";
}
}