hotfix
This commit is contained in:
@@ -27,17 +27,21 @@ namespace ReallifeGamemode.Server.Job
|
||||
|
||||
private void RefuseCollectorJobJobStart(Player player)
|
||||
{
|
||||
if (!playersInThisJob.Contains(player))
|
||||
playersInThisJob.Add(player);
|
||||
//setClothes
|
||||
}
|
||||
|
||||
private void RefuseCollectorJobJobStop(Player player)
|
||||
{
|
||||
if (playersInThisJob.Contains(player))
|
||||
playersInThisJob.Remove(player);
|
||||
//removeClothes and replace with old
|
||||
MuellmannJobBeenden(player);
|
||||
}
|
||||
|
||||
|
||||
|
||||
private List<Player> playersInThisJob = new List<Player>();
|
||||
public List<MuellmannData> muellmanData = new List<MuellmannData>();
|
||||
private List<Vector3> vector3s = new List<Vector3>();
|
||||
|
||||
@@ -143,8 +147,10 @@ namespace ReallifeGamemode.Server.Job
|
||||
{
|
||||
if (data.getDataFromClient(player) == null) continue;
|
||||
|
||||
int count = data.getTrashCount();
|
||||
Console.WriteLine($"[DATA DEBUG] vehicle: {data.vehicle.DisplayName} | Players: {data.getClientsFromData()}");
|
||||
|
||||
int count = data.getTrashCount();
|
||||
|
||||
Player target = data.getPartnerClient(player);
|
||||
if (target != null) ChatService.SendMessage((Player)target, $"Fahrzeug wurde entleert. Säcke: {count}");
|
||||
ChatService.SendMessage((Player)player, $"Fahrzeug wurde entleert. Säcke: {count}");
|
||||
@@ -152,6 +158,7 @@ namespace ReallifeGamemode.Server.Job
|
||||
//bonus pro sack
|
||||
|
||||
data.setTrashCount(0);
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -161,7 +168,7 @@ namespace ReallifeGamemode.Server.Job
|
||||
private void SrvEvent_PlayerDc(Player player)
|
||||
{
|
||||
if (!GetPlayerInJob().Contains(player)) return;
|
||||
if (player.GetUser().JobId != 2) return;
|
||||
if (!playersInThisJob.Contains(player)) return;
|
||||
foreach (var data in muellmanData)
|
||||
{
|
||||
if (data.getDataFromClient(player) == null) continue;
|
||||
@@ -183,7 +190,7 @@ namespace ReallifeGamemode.Server.Job
|
||||
private void SrvEvent_PlayerDeath(Player player)
|
||||
{
|
||||
if (!GetPlayerInJob().Contains(player)) return;
|
||||
if (player.GetUser().JobId != 2) return;
|
||||
if (!playersInThisJob.Contains(player)) return;
|
||||
foreach (var data in muellmanData)
|
||||
{
|
||||
if (data.getDataFromClient(player) == null) continue;
|
||||
@@ -225,7 +232,7 @@ namespace ReallifeGamemode.Server.Job
|
||||
{
|
||||
Player target;
|
||||
if (!GetPlayerInJob().Contains(player)) return;
|
||||
if (player.GetUser().JobId != 2) return;
|
||||
if (!playersInThisJob.Contains(player)) return;
|
||||
|
||||
if (vehicle.Model == (uint)Types.VehicleModel.Trash || vehicle.Model == (uint)Types.VehicleModel.Trash2)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user