mirror of
https://github.com/RaidMax/IW4M-Admin.git
synced 2025-06-10 23:31:13 -05:00
added moment for parsing dates in profile timeline
fixed bug of duplicate penalties fixed showing timeline date for non events refresh player count on server overview fix refresh privileged users on map load fix 1h showing on tempban if manually specified
This commit is contained in:
@ -1,8 +1,4 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
using SharedLibrary.Database.Models;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
@ -13,8 +9,6 @@ namespace StatsPlugin.Models
|
||||
{
|
||||
public class EFClientKill : SharedEntity
|
||||
{
|
||||
public EFClientKill() { }
|
||||
|
||||
[Key]
|
||||
public long KillId { get; set; }
|
||||
public int VictimId { get; set; }
|
||||
|
@ -38,7 +38,12 @@ namespace StatsPlugin.Models
|
||||
public double Skill { get; set; }
|
||||
[Required]
|
||||
public int TimePlayed { get; set; }
|
||||
|
||||
|
||||
[NotMapped]
|
||||
public float AverageHitOffset
|
||||
{
|
||||
get => (float)Math.Round(HitLocations.Sum(c => c.HitOffsetAverage) / HitLocations.Where(c => c.HitOffsetAverage > 0).Count(), 4);
|
||||
}
|
||||
[NotMapped]
|
||||
public int SessionKills { get; set; }
|
||||
[NotMapped]
|
||||
|
@ -1,11 +1,5 @@
|
||||
using SharedLibrary.Database.Models;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace StatsPlugin.Models
|
||||
{
|
||||
@ -17,5 +11,7 @@ namespace StatsPlugin.Models
|
||||
public IW4Info.HitLocation Location { get; set; }
|
||||
[Required]
|
||||
public int HitCount { get; set; }
|
||||
[Required]
|
||||
public float HitOffsetAverage { get; set; }
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user