fix jailtime

This commit is contained in:
hydrant
2019-07-20 14:15:56 +02:00
parent 0a3efd8f63
commit 95e4241610

View File

@@ -48,9 +48,9 @@ namespace ReallifeGamemode.Server.Wanted
User cop = copClient.GetUser();
if (cop?.FactionId == 1 || cop?.FactionId == 3)
{
int jailTime = user.Wanteds * 54;
if (cop.GetData<bool>("duty") && copClient.Position.DistanceTo2D(client.Position) <= 200 && (!copClient.HasData("isDead") || copClient.GetData("isDead") != true))
{
int jailTime = user.Wanteds * 54; ;
using (var dbContext = new DatabaseContext())
{
if (!client.HasData("isDead") || client.GetData("isDead") == false)
@@ -89,8 +89,6 @@ namespace ReallifeGamemode.Server.Wanted
}
}
}
public static void JailTimer()
{
System.Timers.Timer timer = new System.Timers.Timer(60000);