Continue Ammunation
This commit is contained in:
@@ -6,6 +6,7 @@ using ReallifeGamemode.Database.Models;
|
||||
using ReallifeGamemode.Server.Shop.Clothing;
|
||||
using ReallifeGamemode.Server.Shop.SevenEleven;
|
||||
using ReallifeGamemode.Server.Shop.Friseur;
|
||||
using ReallifeGamemode.Server.Shop.Ammunation;
|
||||
|
||||
namespace ReallifeGamemode.Server.Managers
|
||||
{
|
||||
@@ -14,7 +15,7 @@ namespace ReallifeGamemode.Server.Managers
|
||||
public static List<ClotheShop> clotheStores = new List<ClotheShop>();
|
||||
public static List<ItemShop> itemShops = new List<ItemShop>();
|
||||
public static List<Friseur> FriseurStores = new List<Friseur>();
|
||||
public static List<AmmunationPoint> Ammunations = new List<Ammunation>();
|
||||
public static List<Ammunation> Ammunations = new List<Ammunation>();
|
||||
|
||||
public static void LoadClotheShops()
|
||||
{
|
||||
@@ -82,5 +83,20 @@ namespace ReallifeGamemode.Server.Managers
|
||||
}
|
||||
}
|
||||
|
||||
public static void LoadAmmunations()
|
||||
{
|
||||
using (var dbContext = new DatabaseContext())
|
||||
{
|
||||
List<SavedBlip> ammunations = dbContext.Blips.ToList().FindAll(s => s.Name == "Ammunation");
|
||||
|
||||
foreach (var store in ammunations)
|
||||
{
|
||||
Vector3 pos = new Vector3(store.PositionX, store.PositionY, store.PositionZ);
|
||||
Ammunation newShop = new Ammunation(pos);
|
||||
Ammunations.Add(newShop);
|
||||
}
|
||||
NAPI.Util.ConsoleOutput($"Loading {ammunations.Count} Ammunations");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,15 +37,15 @@ namespace ReallifeGamemode.Server.Shop.Ammunation
|
||||
return;
|
||||
}
|
||||
|
||||
//List<Weapon> melee = weaponList.ToList().FindAll(w => w.Category == "Pistol");
|
||||
List<Weapon> handguns = weaponList.ToList().FindAll(w => w.Category == "Handgun");
|
||||
//List<Weapon> smgs = weaponList.ToList().FindAll(w => w.Category == "SMG");
|
||||
//List<Weapon> shotguns = weaponList.ToList().FindAll(w => w.Category == "Shotgun");
|
||||
//List<Weapon> assaultrifles = weaponList.ToList().FindAll(w => w.Category == "AssaultRifle");
|
||||
//List<Weapon> lmgs = weaponList.ToList().FindAll(w => w.Category == "LMG");
|
||||
//List<Weapon> sniperrifles = weaponList.ToList().FindAll(w => w.Category == "SniperRifle");
|
||||
//List<Weapon> heavyweapons = weaponList.ToList().FindAll(w => w.Category == "HeavyWeapon");
|
||||
//List<Weapon> throwables = weaponList.ToList().FindAll(w => w.Category == "Throwables");
|
||||
//List<Weapon> melee = weaponList.ToList().FindAll(w => w.Category == "Nahkampfwaffen");
|
||||
List<Weapon> handguns = weaponList.ToList().FindAll(w => w.Category == "Pistolen");
|
||||
//List<Weapon> smgs = weaponList.ToList().FindAll(w => w.Category == "Maschinenpistolen");
|
||||
//List<Weapon> shotguns = weaponList.ToList().FindAll(w => w.Category == "Schrotflinten");
|
||||
//List<Weapon> assaultrifles = weaponList.ToList().FindAll(w => w.Category == "Sturmgewehre");
|
||||
//List<Weapon> lmgs = weaponList.ToList().FindAll(w => w.Category == "Leichte Maschinengewehre");
|
||||
//List<Weapon> sniperrifles = weaponList.ToList().FindAll(w => w.Category == "Scharfschützengewehre");
|
||||
//List<Weapon> heavyweapons = weaponList.ToList().FindAll(w => w.Category == "Schwere Waffen");
|
||||
//List<Weapon> throwables = weaponList.ToList().FindAll(w => w.Category == "Werfbare Waffen");
|
||||
|
||||
List<Array> shopWeapons = new List<Array>
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user