// <auto-generated />
using System;
using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Infrastructure;
using Microsoft.EntityFrameworkCore.Migrations;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using ReallifeGamemode.Database.Models;

namespace ReallifeGamemode.Database.Migrations
{
    [DbContext(typeof(DatabaseContext))]
    [Migration("20200315113621_BankAccountRefactor")]
    partial class BankAccountRefactor
    {
        protected override void BuildTargetModel(ModelBuilder modelBuilder)
        {
#pragma warning disable 612, 618
            modelBuilder
                .HasAnnotation("ProductVersion", "2.1.11-servicing-32099")
                .HasAnnotation("Relational:MaxIdentifierLength", 64);

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ATM", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<int>("Balance");

                    b.Property<bool>("Faulty");

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.ToTable("ATMs");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Ban", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Applied");

                    b.Property<string>("BannedBy");

                    b.Property<string>("Reason");

                    b.Property<int>("UntilDateTime");

                    b.Property<int>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("Bans");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.BusinessBankAccount", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Balance");

                    b.Property<int>("BusinessId");

                    b.HasKey("Id");

                    b.HasIndex("BusinessId")
                        .IsUnique();

                    b.ToTable("BusinessBankAccounts");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.BusinessData", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("BusinessId");

                    b.Property<int>("Price");

                    b.HasKey("Id");

                    b.ToTable("BusinessData");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.BusRoute", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("Description");

                    b.HasKey("Id");

                    b.ToTable("BusRoutes");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.BusRoutePoint", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int?>("BusRouteId");

                    b.Property<string>("Description");

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.HasIndex("BusRouteId");

                    b.ToTable("BusRoutesPoints");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Character", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<byte>("Ageing");

                    b.Property<float>("AgeingOpacity");

                    b.Property<byte>("BeardColor");

                    b.Property<byte>("Blemishes");

                    b.Property<float>("BlemishesOpacity");

                    b.Property<byte>("Blush");

                    b.Property<byte>("BlushColor");

                    b.Property<float>("BlushOpacity");

                    b.Property<float>("BrowDepth");

                    b.Property<float>("BrowHeight");

                    b.Property<float>("CheekDepth");

                    b.Property<float>("CheekboneHeight");

                    b.Property<float>("CheekboneWidth");

                    b.Property<byte>("ChestHair");

                    b.Property<byte>("ChestHairColor");

                    b.Property<float>("ChestHairOpacity");

                    b.Property<float>("ChinDepth");

                    b.Property<float>("ChinHeight");

                    b.Property<float>("ChinIndent");

                    b.Property<float>("ChinWidth");

                    b.Property<byte>("Complexion");

                    b.Property<float>("ComplexionOpacity");

                    b.Property<byte>("EyeColor");

                    b.Property<float>("EyeSize");

                    b.Property<byte>("EyebrowColor");

                    b.Property<byte>("Eyebrows");

                    b.Property<float>("EyebrowsOpacity");

                    b.Property<byte>("FacialHair");

                    b.Property<float>("FacialHairOpacity");

                    b.Property<byte>("Father");

                    b.Property<byte>("Freckles");

                    b.Property<float>("FrecklesOpacity");

                    b.Property<bool>("Gender");

                    b.Property<byte>("Hair");

                    b.Property<byte>("HairColor");

                    b.Property<byte>("HairHighlightColor");

                    b.Property<float>("JawShape");

                    b.Property<float>("JawWidth");

                    b.Property<float>("LipThickness");

                    b.Property<byte>("Lipstick");

                    b.Property<byte>("LipstickColor");

                    b.Property<float>("LipstickOpacity");

                    b.Property<byte>("Makeup");

                    b.Property<float>("MakeupOpacity");

                    b.Property<byte>("Mother");

                    b.Property<float>("NeckWidth");

                    b.Property<float>("NoseBottomHeight");

                    b.Property<float>("NoseBridgeDepth");

                    b.Property<float>("NoseBroken");

                    b.Property<float>("NoseTipHeight");

                    b.Property<float>("NoseTipLength");

                    b.Property<float>("NoseWidth");

                    b.Property<float>("Similarity");

                    b.Property<float>("SkinSimilarity");

                    b.Property<byte>("SunDamage");

                    b.Property<float>("SunDamageOpacity");

                    b.Property<int>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("Characters");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.CharacterCloth", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("ClothId");

                    b.Property<bool>("Duty");

                    b.Property<int>("SlotId");

                    b.Property<byte>("SlotType");

                    b.Property<int>("Texture");

                    b.Property<int>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("CharacterClothes");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ClothCombination", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Gender");

                    b.Property<int>("Top");

                    b.Property<int>("Torso");

                    b.Property<int>("Undershirt");

                    b.HasKey("Id");

                    b.ToTable("ClothCombinations");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Door", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("Category");

                    b.Property<int?>("FactionId");

                    b.Property<bool>("Locked");

                    b.Property<int>("Model");

                    b.Property<string>("Name");

                    b.Property<float>("Radius");

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.HasIndex("FactionId");

                    b.ToTable("Doors");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.DutyCloth", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("ClothId");

                    b.Property<int>("FactionId");

                    b.Property<bool>("Gender");

                    b.Property<int>("SlotId");

                    b.Property<byte>("SlotType");

                    b.HasKey("Id");

                    b.HasIndex("FactionId");

                    b.ToTable("DutyClothes");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Faction", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int?>("BankAccountId");

                    b.Property<string>("Name")
                        .HasMaxLength(32);

                    b.Property<bool>("StateOwned");

                    b.Property<int>("WeaponDealTime");

                    b.HasKey("Id");

                    b.HasIndex("BankAccountId");

                    b.ToTable("Factions");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionBankAccount", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<int>("Balance");

                    b.Property<string>("Bic")
                        .HasMaxLength(12);

                    b.Property<string>("Iban")
                        .HasMaxLength(32);

                    b.HasKey("Id");

                    b.ToTable("FactionBankAccounts");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionRank", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("FactionId");

                    b.Property<int>("Order");

                    b.Property<string>("RankName");

                    b.HasKey("Id");

                    b.HasIndex("FactionId");

                    b.ToTable("FactionRanks");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionWeapon", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Ammount");

                    b.Property<int?>("FactionId");

                    b.Property<int>("Rank");

                    b.Property<int>("SlotID");

                    b.Property<string>("WeaponModel");

                    b.HasKey("Id");

                    b.HasIndex("FactionId");

                    b.ToTable("FactionWeapons");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.GotoPoint", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<string>("Description")
                        .HasMaxLength(32);

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.ToTable("GotoPoints");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Group", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int?>("BankAccountId");

                    b.Property<string>("Name");

                    b.HasKey("Id");

                    b.HasIndex("BankAccountId");

                    b.ToTable("Groups");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.GroupBankAccount", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Balance");

                    b.HasKey("Id");

                    b.ToTable("GroupBankAccounts");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.House", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("CanRentIn");

                    b.Property<int?>("OwnerId");

                    b.Property<int>("Price");

                    b.Property<int>("RentalFee");

                    b.Property<string>("Type");

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.HasIndex("OwnerId");

                    b.ToTable("Houses");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.HouseRental", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int?>("HouseId");

                    b.Property<int?>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("HouseId");

                    b.HasIndex("UserId");

                    b.ToTable("HouseRentals");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Interior", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("EnterPositionStr")
                        .HasColumnName("EnterPosition");

                    b.Property<string>("ExitPositionStr")
                        .HasColumnName("ExitPosition");

                    b.Property<string>("Name");

                    b.HasKey("Id");

                    b.ToTable("Interiors");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Location", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("Description");

                    b.Property<double>("Heading");

                    b.Property<double>("X");

                    b.Property<double>("Y");

                    b.Property<double>("Z");

                    b.HasKey("Id");

                    b.ToTable("Locations");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Logs.BankAccountTransactionHistory", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Fee");

                    b.Property<int>("MoneySent");

                    b.Property<int>("NewReceiverBalance");

                    b.Property<int>("NewSenderBalance");

                    b.Property<string>("Origin")
                        .HasMaxLength(32);

                    b.Property<string>("Receiver")
                        .HasMaxLength(32);

                    b.Property<int>("ReceiverBalance");

                    b.Property<string>("Sender")
                        .HasMaxLength(32);

                    b.Property<int>("SenderBalance");

                    b.Property<DateTime>("Timestamp")
                        .ValueGeneratedOnAdd();

                    b.HasKey("Id");

                    b.ToTable("BankAccountTransactionLogs");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Logs.Death", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("CauseOfDeath")
                        .HasMaxLength(64);

                    b.Property<float>("KillerHeading");

                    b.Property<int?>("KillerId");

                    b.Property<float>("KillerPositionX");

                    b.Property<float>("KillerPositionY");

                    b.Property<float>("KillerPositionZ");

                    b.Property<DateTime>("Timestamp")
                        .ValueGeneratedOnAdd();

                    b.Property<float>("VictimHeading");

                    b.Property<int>("VictimId");

                    b.Property<float>("VictimPositionX");

                    b.Property<float>("VictimPositionY");

                    b.Property<float>("VictimPositionZ");

                    b.HasKey("Id");

                    b.HasIndex("KillerId");

                    b.HasIndex("VictimId");

                    b.ToTable("DeathLogs");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.News", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<string>("Caption");

                    b.Property<string>("Content");

                    b.Property<int>("Timestamp");

                    b.Property<int?>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("News");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedBlip", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<byte>("Alpha");

                    b.Property<byte>("Color");

                    b.Property<byte>("Dimension");

                    b.Property<float>("DrawDistance");

                    b.Property<string>("Name");

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<float>("Rotation");

                    b.Property<float>("Scale");

                    b.Property<bool>("ShortRange");

                    b.Property<short>("Sprite");

                    b.HasKey("Id");

                    b.ToTable("Blips");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedMarker", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<byte>("ColorA");

                    b.Property<byte>("ColorB");

                    b.Property<byte>("ColorG");

                    b.Property<byte>("ColorR");

                    b.Property<byte>("Dimension");

                    b.Property<float>("DirectionX");

                    b.Property<float>("DirectionY");

                    b.Property<float>("DirectionZ");

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<float>("RotationX");

                    b.Property<float>("RotationY");

                    b.Property<float>("RotationZ");

                    b.Property<float>("Scale");

                    b.Property<byte>("Type");

                    b.Property<bool>("Visible");

                    b.HasKey("Id");

                    b.ToTable("Markers");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedPed", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<byte>("Dimension");

                    b.Property<string>("HashModel");

                    b.Property<float>("Heading");

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.HasKey("Id");

                    b.ToTable("Peds");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedPickup", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<byte>("Dimension");

                    b.Property<float>("PositionX")
                        .HasMaxLength(128);

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<int>("RespawnTime");

                    b.Property<float>("RotationX");

                    b.Property<float>("RotationY");

                    b.Property<float>("RotationZ");

                    b.Property<bool>("Vehicle");

                    b.HasKey("Id");

                    b.ToTable("Pickups");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedTextLabel", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<byte>("ColorA");

                    b.Property<byte>("ColorB");

                    b.Property<byte>("ColorG");

                    b.Property<byte>("ColorR");

                    b.Property<byte>("Dimension");

                    b.Property<float>("DrawDistance");

                    b.Property<byte>("Font");

                    b.Property<bool>("LOS");

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<string>("Text")
                        .IsRequired();

                    b.HasKey("Id");

                    b.ToTable("TextLabels");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ServerVehicle", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active")
                        .ValueGeneratedOnAdd()
                        .HasDefaultValue(true);

                    b.Property<string>("Discriminator")
                        .IsRequired();

                    b.Property<float>("DistanceDriven");

                    b.Property<float>("Heading");

                    b.Property<int>("Livery");

                    b.Property<bool>("Locked");

                    b.Property<uint>("Model");

                    b.Property<string>("NumberPlate")
                        .HasMaxLength(8);

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<int>("PrimaryColor");

                    b.Property<int>("SecondaryColor");

                    b.Property<float>("TankAmount");

                    b.HasKey("Id");

                    b.ToTable("ServerVehicles");

                    b.HasDiscriminator<string>("Discriminator").HasValue("ServerVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ShopClothe", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Category");

                    b.Property<int>("ClotheId");

                    b.Property<int>("ComponentId");

                    b.Property<bool>("Gender");

                    b.Property<int>("Price");

                    b.Property<string>("TypeId");

                    b.HasKey("Id");

                    b.ToTable("ShopClothes");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ShopItem", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Amount");

                    b.Property<int>("ItemId");

                    b.Property<int>("Price");

                    b.Property<int>("ShopId");

                    b.HasKey("Id");

                    b.ToTable("ShopItems");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.TuningGarage", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.Property<float>("Z");

                    b.HasKey("Id");

                    b.ToTable("TuningGarages");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Turfs", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Color");

                    b.Property<int?>("FactionId");

                    b.Property<string>("Name");

                    b.Property<string>("Owner");

                    b.Property<float>("Range");

                    b.Property<float>("Rotation");

                    b.Property<string>("Vector");

                    b.Property<float>("X");

                    b.Property<float>("Y");

                    b.HasKey("Id");

                    b.ToTable("Turfs");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.User", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("AdminLevel");

                    b.Property<int?>("BanId");

                    b.Property<int?>("BankAccountId");

                    b.Property<int?>("BusinessId");

                    b.Property<int?>("CharacterId");

                    b.Property<bool>("Dead");

                    b.Property<bool>("DriverLicenseBike");

                    b.Property<bool>("DriverLicenseVehicle");

                    b.Property<string>("Email")
                        .HasMaxLength(64);

                    b.Property<int?>("FactionId");

                    b.Property<bool>("FactionLeader");

                    b.Property<int?>("FactionRankId");

                    b.Property<bool>("FlyingLicensePlane");

                    b.Property<int?>("GroupId");

                    b.Property<int>("GroupRank");

                    b.Property<int>("Handmoney");

                    b.Property<int?>("HouseId");

                    b.Property<int>("JailTime");

                    b.Property<int?>("JobId");

                    b.Property<int>("LogUserId");

                    b.Property<string>("Name")
                        .HasMaxLength(32);

                    b.Property<string>("Password")
                        .HasMaxLength(64);

                    b.Property<int>("PaydayTimer");

                    b.Property<float>("PositionX");

                    b.Property<float>("PositionY");

                    b.Property<float>("PositionZ");

                    b.Property<DateTime>("RegistrationDate")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("SocialClubName")
                        .HasMaxLength(32);

                    b.Property<int>("Wage");

                    b.Property<int>("Wanteds");

                    b.Property<bool>("WeaponLicense");

                    b.HasKey("Id");

                    b.HasIndex("BanId");

                    b.HasIndex("BankAccountId");

                    b.HasIndex("BusinessId")
                        .IsUnique();

                    b.HasIndex("CharacterId");

                    b.HasIndex("FactionId");

                    b.HasIndex("FactionRankId");

                    b.HasIndex("GroupId");

                    b.HasIndex("HouseId");

                    b.ToTable("Users");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.UserBankAccount", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<bool>("Active");

                    b.Property<int>("Balance");

                    b.Property<string>("Bic")
                        .HasMaxLength(12);

                    b.Property<string>("Iban")
                        .HasMaxLength(32);

                    b.HasKey("Id");

                    b.ToTable("UserBankAccounts");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.UserItem", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Amount");

                    b.Property<int>("ItemId");

                    b.Property<int>("Slot");

                    b.Property<int>("UserId");

                    b.HasKey("Id");

                    b.HasIndex("UserId");

                    b.ToTable("UserItems");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.VehicleItem", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("Amount");

                    b.Property<int>("ItemId");

                    b.Property<int>("Slot");

                    b.Property<int>("VehicleId");

                    b.HasKey("Id");

                    b.HasIndex("VehicleId");

                    b.ToTable("VehicleItems");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.VehicleMod", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<int>("ModId");

                    b.Property<int>("ServerVehicleId");

                    b.Property<int>("Slot");

                    b.HasKey("Id");

                    b.HasIndex("ServerVehicleId", "Slot")
                        .IsUnique();

                    b.ToTable("VehicleMods");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Whitelist", b =>
                {
                    b.Property<int>("Id")
                        .ValueGeneratedOnAdd();

                    b.Property<string>("SocialClubName");

                    b.HasKey("Id");

                    b.ToTable("WhitelistEntries");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int?>("FactionId");

                    b.HasIndex("FactionId");

                    b.ToTable("FactionVehicles");

                    b.HasDiscriminator().HasValue("FactionVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.GroupVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int?>("GroupId");

                    b.HasIndex("GroupId");

                    b.ToTable("GroupVehicle");

                    b.HasDiscriminator().HasValue("GroupVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.JobVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int>("JobId");

                    b.ToTable("JobVehicle");

                    b.HasDiscriminator().HasValue("JobVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Saves.SavedVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");


                    b.ToTable("SavedVehicle");

                    b.HasDiscriminator().HasValue("SavedVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.SchoolVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int>("SchoolId");

                    b.ToTable("SchoolVehicle");

                    b.HasDiscriminator().HasValue("SchoolVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.ShopVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int>("BusinessId");

                    b.Property<int>("Price");

                    b.ToTable("ShopVehicles");

                    b.HasDiscriminator().HasValue("ShopVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.UserVehicle", b =>
                {
                    b.HasBaseType("ReallifeGamemode.Database.Entities.ServerVehicle");

                    b.Property<int>("UserId");

                    b.HasIndex("UserId");

                    b.ToTable("UserVehicles");

                    b.HasDiscriminator().HasValue("UserVehicle");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Ban", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.BusRoutePoint", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.BusRoute", "BusRoute")
                        .WithMany("RoutePoints")
                        .HasForeignKey("BusRouteId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Character", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.CharacterCloth", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Door", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.DutyCloth", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Faction", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.FactionBankAccount", "BankAccount")
                        .WithMany()
                        .HasForeignKey("BankAccountId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionRank", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionWeapon", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Group", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.GroupBankAccount", "BankAccount")
                        .WithMany()
                        .HasForeignKey("BankAccountId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.House", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "Owner")
                        .WithMany()
                        .HasForeignKey("OwnerId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.HouseRental", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.House", "House")
                        .WithMany()
                        .HasForeignKey("HouseId");

                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.Logs.Death", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "Killer")
                        .WithMany()
                        .HasForeignKey("KillerId");

                    b.HasOne("ReallifeGamemode.Database.Entities.User", "Victim")
                        .WithMany()
                        .HasForeignKey("VictimId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.News", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.User", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Ban", "Ban")
                        .WithMany()
                        .HasForeignKey("BanId");

                    b.HasOne("ReallifeGamemode.Database.Entities.UserBankAccount", "BankAccount")
                        .WithMany()
                        .HasForeignKey("BankAccountId");

                    b.HasOne("ReallifeGamemode.Database.Entities.Character", "Character")
                        .WithMany()
                        .HasForeignKey("CharacterId");

                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId");

                    b.HasOne("ReallifeGamemode.Database.Entities.FactionRank", "FactionRank")
                        .WithMany()
                        .HasForeignKey("FactionRankId");

                    b.HasOne("ReallifeGamemode.Database.Entities.Group", "Group")
                        .WithMany()
                        .HasForeignKey("GroupId");

                    b.HasOne("ReallifeGamemode.Database.Entities.House", "House")
                        .WithMany()
                        .HasForeignKey("HouseId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.UserItem", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.VehicleItem", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.ServerVehicle", "Vehicle")
                        .WithMany()
                        .HasForeignKey("VehicleId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.VehicleMod", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.ServerVehicle", "Vehicle")
                        .WithMany()
                        .HasForeignKey("ServerVehicleId")
                        .OnDelete(DeleteBehavior.Cascade);
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.FactionVehicle", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Faction", "Faction")
                        .WithMany()
                        .HasForeignKey("FactionId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.GroupVehicle", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.Group", "Group")
                        .WithMany()
                        .HasForeignKey("GroupId");
                });

            modelBuilder.Entity("ReallifeGamemode.Database.Entities.UserVehicle", b =>
                {
                    b.HasOne("ReallifeGamemode.Database.Entities.User", "User")
                        .WithMany()
                        .HasForeignKey("UserId")
                        .OnDelete(DeleteBehavior.Cascade);
                });
#pragma warning restore 612, 618
        }
    }
}
