1
0
mirror of https://github.com/RaidMax/IW4M-Admin.git synced 2025-06-10 15:20:48 -05:00

migrating Stats to .Net Core 2

moved buildscripts to application
added publish profile
This commit is contained in:
RaidMax
2018-04-08 16:50:58 -05:00
parent 599027c4b6
commit d0c2a86ce8
69 changed files with 1486 additions and 720 deletions

View File

@ -0,0 +1,42 @@
using System;
using SharedLibraryCore.Database.Models;
using System.ComponentModel.DataAnnotations.Schema;
using SharedLibraryCore.Helpers;
using System.ComponentModel.DataAnnotations;
namespace IW4MAdmin.Plugins.Stats.Models
{
public class EFClientKill : SharedEntity
{
[Key]
public long KillId { get; set; }
public int VictimId { get; set; }
[ForeignKey("VictimId")]
public virtual EFClient Victim { get; set; }
public int AttackerId { get; set; }
[ForeignKey("AttackerId")]
public virtual EFClient Attacker { get; set; }
public int ServerId { get; set; }
[ForeignKey("ServerId")]
public virtual EFServer Server { get; set; }
public IW4Info.HitLocation HitLoc { get; set; }
public IW4Info.MeansOfDeath DeathType { get; set; }
public int Damage { get; set; }
public IW4Info.WeaponName Weapon { get; set; }
public Vector3 KillOrigin { get; set; }
public Vector3 DeathOrigin { get; set; }
public Vector3 ViewAngles { get; set; }
public DateTime When { get; set; }
// http://wiki.modsrepository.com/index.php?title=Call_of_Duty_5:_Gameplay_standards for conversion to meters
[NotMapped]
public double Distance => Vector3.Distance(KillOrigin, DeathOrigin) * 0.0254;
public IW4Info.MapName Map { get; set; }
[NotMapped]
public long TimeOffset { get; set; }
[NotMapped]
public bool IsKillstreakKill { get; set; }
[NotMapped]
public float AdsPercent { get; set; }
}
}