add armor as lonley item

This commit is contained in:
Michael
2020-06-08 18:07:36 +02:00
parent 2cf5d979dc
commit ee90e85ebd
3 changed files with 34 additions and 12 deletions

View File

@@ -341,6 +341,7 @@ namespace ReallifeGamemode.Server.Events
List<string> secondarys = new List<string>();
List<string> melees = new List<string>();
List<string> specials = new List<string>();
List<string> armor = new List<string>();
List<string> timer = new List<string>();
int pistol_Amount = 0;
int pistol50_Amount = 0;
@@ -358,6 +359,7 @@ namespace ReallifeGamemode.Server.Events
secondarys.Add("Keine");
melees.Add("Keine");
specials.Add("Keine");
armor.Add("Keine");
using (var context = new DatabaseContext())
{
@@ -428,6 +430,11 @@ namespace ReallifeGamemode.Server.Events
if (user.FactionRank.Order >= weapon.Rank)
specials.Add(weapon.WeaponModel.ToString());
break;
case 5:
if (user.FactionRank.Order >= weapon.Rank)
armor.Add(weapon.WeaponModel.ToString());
break;
}
}
@@ -478,7 +485,7 @@ namespace ReallifeGamemode.Server.Events
}
}
player.TriggerEvent("showWeaponMenu", primarys.ToArray(), secondarys.ToArray(), melees.ToArray(), specials.ToArray(), JsonConvert.SerializeObject(timer.ToArray()), pistol_Amount.ToString(), pistol50_Amount.ToString(), Pistol_mk2_Amount.ToString(), Combatpistol_Amount.ToString(), SMG_Amount.ToString(), Carbinerifle_Amount.ToString(), Compactrifle_Amount.ToString(), sniperrifle_Amount.ToString(), Pumpshotgun_Amount.ToString(), Schutzweste_Amount.ToString(), Stungun_Amount.ToString());
player.TriggerEvent("showWeaponMenu", primarys.ToArray(), secondarys.ToArray(), melees.ToArray(), specials.ToArray(), armor.ToArray(), JsonConvert.SerializeObject(timer.ToArray()), pistol_Amount.ToString(), pistol50_Amount.ToString(), Pistol_mk2_Amount.ToString(), Combatpistol_Amount.ToString(), SMG_Amount.ToString(), Carbinerifle_Amount.ToString(), Compactrifle_Amount.ToString(), sniperrifle_Amount.ToString(), Pumpshotgun_Amount.ToString(), Schutzweste_Amount.ToString(), Stungun_Amount.ToString()); ;
}
if (nearestJailReleasePoint != null)
{