2017-05-27 18:08:04 -04:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Text;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
using SharedLibrary;
|
|
|
|
|
|
|
|
|
|
namespace IW4MAdmin
|
|
|
|
|
{
|
|
|
|
|
class PenaltyList : SharedLibrary.Interfaces.IPenaltyList
|
|
|
|
|
{
|
|
|
|
|
public PenaltyList()
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void AddPenalty(Penalty P)
|
|
|
|
|
{
|
2017-06-19 13:58:01 -04:00
|
|
|
|
ApplicationManager.GetInstance().GetClientDatabase().AddBan(P);
|
2017-05-27 18:08:04 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void RemovePenalty(Penalty P)
|
|
|
|
|
{
|
2017-06-19 13:58:01 -04:00
|
|
|
|
ApplicationManager.GetInstance().GetClientDatabase().RemoveBan(P.OffenderID);
|
2017-05-27 18:08:04 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public List<Penalty> FindPenalties(Player P)
|
|
|
|
|
{
|
2017-06-19 13:58:01 -04:00
|
|
|
|
return ApplicationManager.GetInstance().GetClientDatabase().GetClientPenalties(P);
|
2017-05-27 18:08:04 -04:00
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public List<Penalty> AsChronoList(int offset, int count)
|
|
|
|
|
{
|
2017-06-19 13:58:01 -04:00
|
|
|
|
return ApplicationManager.GetInstance().GetClientDatabase().GetPenaltiesChronologically(offset, count);
|
2017-05-27 18:08:04 -04:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|