sani benachrichtigungen bei tod und arevive

This commit is contained in:
Fabian
2021-04-14 21:16:14 +02:00
parent cb61e860a9
commit 402e6ee048
2 changed files with 8 additions and 0 deletions

View File

@@ -1402,6 +1402,7 @@ namespace ReallifeGamemode.Server.Commands
}
target.TriggerEvent("onPlayerRevived");
target.SendNotification("Du wurdest von Admin ~y~" + player.Name + "~s~ wiederbelebt.");
ChatService.BroadcastFaction("Info: " + "Der Auftrag von " + target.Name + " wurde entfernt (Administrativ wiederbelebt)", new List<int>() { 2 });
target.SetData("isDead", false);
using (var dbContext = new DatabaseContext())
{

View File

@@ -62,6 +62,13 @@ namespace ReallifeGamemode.Server.Events
{
ChatService.BroadcastAdmin("!{#FFFF00}*** " + player.Name + " hat den Server verlassen", AdminLevel.MAPPING);
}
if (!player.HasData("isDead") || !player.GetData<bool>("isDead"))
{
ChatService.BroadcastFaction("Info: " + "Der Auftrag von " + player.Name + " wurde entfernt (Ausgeloggt)", new List<int>() { 2 });
return;
}
/*
TaxiDriverJob taxiJob = JobManager.GetJob<TaxiDriverJob>();
TaxiContract taxiContract = taxiJob.TaxiContracts.Where(t => t.Name == player.Name).FirstOrDefault();