コード例 #1
0
    public static void init(SCBaseInfo baseInfo)
    {
        gold = baseInfo.Gold;
        foreach (PBItemTable it in baseInfo.ItemTable)
        {
            ItemTable itemTable = new ItemTable();
            itemTable.Id       = it.Id;
            itemTable.ItemType = it.ItemType;
            itemTable.Para1    = it.Para1;
            itemTable.Para2    = it.Para2;
            itemTable.Price    = it.Price;
            itemTables.Add(itemTable.Id, itemTable);
        }

        foreach (PBUnitTable ut in baseInfo.UnitTable)
        {
            UnitTable unitTable = new UnitTable();
            unitTable.Id = ut.Id;
            string[] itemStrs = ut.Items.Split('|');
            unitTable.Items = new Dictionary <int, int> ();
            foreach (string itemStr in itemStrs)
            {
                if (itemStr.Length == 0)
                {
                    continue;
                }
                string[] strs = itemStr.Split(';');
                unitTable.Items.Add(int.Parse(strs[0]), int.Parse(strs[1]));
            }
            unitTable.Price = ut.Price;
            unitTables.Add(unitTable.Id, unitTable);
        }

        foreach (PBPeckTable pt in baseInfo.PeckTable)
        {
            PeckTable peckTable = new PeckTable();
            peckTable.Id      = pt.Id;
            peckTable.gold    = pt.Gold;
            peckTable.goldNum = pt.Gold;
            if (pt.Items != null && pt.Items.Length > 0)
            {
                peckTable.Items = new Dictionary <int, int> ();
                string[] itemStrs = pt.Items.Split('|');
                peckTable.Items = new Dictionary <int, int> ();
                foreach (string itemStr in itemStrs)
                {
                    if (itemStr.Length == 0)
                    {
                        continue;
                    }
                    string[] strs = itemStr.Split(';');
                    peckTable.Items.Add(int.Parse(strs[0]), int.Parse(strs[1]));
                }
            }
            peckTable.Price = pt.Price;

            peckTables.Add(peckTable.Id, peckTable);
        }
    }
コード例 #2
0
ファイル: Unit.cs プロジェクト: acmercyj/Framework
 /// <summary>
 /// 创建
 /// </summary>
 public virtual void Create(int id)
 {
     Table = SheetManager.Instance.GetSheetInfo <UnitTable>(id);
     VisualManager.Instance.CreateVisual(this);
     Dead.Value = false;
     Position.AddChangeListener(ChangePosition);
     Forward.AddChangeListener(ChangeForward);
 }
コード例 #3
0
ファイル: ResManager.cs プロジェクト: glms123/test
 public void LoadInitTable()
 {
     LoadTable <MiscTable>(ResManager.MISC_TABLE, (value) => {
         ResManager.Instance.miscTable = value;
         ResManager.Instance.miscTable.Init();
     });
     LoadTable <AudioTable>(ResManager.AUDIO_TABLE, (value) => { ResManager.Instance.audioTable = value; });
     LoadTable <LocalizationTable>(ResManager.LOCALIZATION_TABLE, (value) => { ResManager.Instance.localizationTable = value; });
     LoadTable <SceneTable>(ResManager.SCENE_TABLE, (value) => { ResManager.Instance.sceneTable = value; });
     LoadTable <LevelTable>(ResManager.LEVEL_TABLE, (value) => { ResManager.Instance.levelTable = value; });
     LoadTable <DialogueTable>(DIALOGUE_TABLE, (value) => { dialogueTable = value; });
     LoadTable <CardTable>(CARD_TABLE, (value) => { cardTable = value; });
     LoadTable <UnitTable>(UNIT_TABLE, (value) => { unitTable = value; });
 }
コード例 #4
0
    // 买完回调
    public void buyFinish(bool success, int shopType, int id, int num, int gold)
    {
        if (!success)
        {
            WarnDialog.showWarnDialog(Message.getText("buyFail"));
            return;
        }
        Params.gold   = gold;
        goldText.text = Params.gold.ToString();

//		WarnDialog.showWarnDialog("buy success,type = "+shopType+",itemId = "+id+",num = "+num);

        show.SetActive(true);

        ShopType type = (ShopType)shopType;

        if (type == ShopType.Item)         // 道具用的时候是实时获得的,所以,啥都不做
        {
            showItemByCount(1);
            showIn(id, num, 0);
        }
        else if (type == ShopType.Unit)          // 道具用的时候是实时获得的,所以,啥都不做
        {
            UnitTable unitTable = Params.unitTables[id];
            showItemByCount(unitTable.Items.Count);
            int index = 0;
            foreach (KeyValuePair <int, int> kv in unitTable.Items)
            {
                showIn(kv.Key, kv.Value * num, index++);
            }
        }
        else if (type == ShopType.Peck)          //
        {
            PeckTable peckTable = Params.peckTables[id];
            if (peckTable.gold > 0)
            {
                Sprite sp = ShopItem.getGoldSprite();
                showItemImage[0].sprite = sp;
                showItemText [0].text   = "x" + (peckTable.gold * num);
            }

            int index = peckTable.gold > 0?1:0;
            foreach (KeyValuePair <int, int> kv in peckTable.Items)
            {
                showIn(kv.Key, kv.Value * num, index++);
            }
            showItemByCount(index);
        }
    }
コード例 #5
0
ファイル: ConverterCommand.cs プロジェクト: fossabot/WizBot
        private int LookupUnit(UnitTable table, string lookup)
        {
            string wellformedLookup = lookup.ToLowerInvariant().Replace("°", "");
            int    i = 1;

            while (table.IsKnownUnit(i))
            {
                if (wellformedLookup == table.GetUnitName(i).ToLowerInvariant().Replace("°", "") ||
                    wellformedLookup == table.GetUnitPlural(i).ToLowerInvariant().Replace("°", "") ||
                    wellformedLookup == table.GetUnitSymbol(i).ToLowerInvariant().Replace("°", ""))
                {
                    return(i);
                }
                i++;
            }
            return(0);
        }
コード例 #6
0
    public void Init(UnitTable _UnitTable)
    {
#if UNITY_EDITOR
        if (_UnitTable == null)
        {
            Debug.LogError("UnitTable이 없다");
            return;
        }
#endif
        UnitTable      = _UnitTable;
        UnitDictionary = new Dictionary <string, UnitTable.UnitStatus>();

        for (int i = 0; i < UnitTable.Units.Length; i++)
        {
            UnitDictionary.Add(UnitTable.Units[i].UnitName, UnitTable.Units[i]);
        }
    }
コード例 #7
0
    public void Init(UnitTable tableFromManager)
    {
        m_AssetUnitTable = tableFromManager;
        m_UnitDic        = new Dictionary <string, UnitTable.UnitStats>();

        if (m_AssetUnitTable == null)
        {
            Debug.LogError("You Missed DataTable in GameManager");
            return;
        }

        foreach (var Unit in m_AssetUnitTable.m_Units)
        {
            m_UnitDic.Add(Unit.m_ClassName, Unit);
        }

        Debug.Log("DataTable:" + m_AssetUnitTable.name + " Init Successful !,DataCount:" + m_UnitDic.Count);
    }
コード例 #8
0
ファイル: ConverterCommand.cs プロジェクト: fossabot/WizBot
 private void ResolveUnitCodes(string from, string to, out UnitTable table, out int fromCode, out int toCode)
 {
     foreach (var tmpTable in unitTables)
     {
         int f = LookupUnit(tmpTable, from);
         int t = LookupUnit(tmpTable, to);
         if (f > 0 && t > 0)
         {
             table    = tmpTable;
             fromCode = f;
             toCode   = t;
             return;
         }
     }
     table    = null;
     fromCode = 0;
     toCode   = 0;
 }
コード例 #9
0
ファイル: ConverterCommand.cs プロジェクト: fossabot/WizBot
        private Func <CommandEventArgs, Task> ConvertFunc() =>
        async e =>
        {
            try
            {
                await e.Channel.SendIsTyping().ConfigureAwait(false);

                string from = e.GetArg("from-to").ToLowerInvariant().Split('>')[0];
                string to   = e.GetArg("from-to").ToLowerInvariant().Split('>')[1];

                float quantity = 1.0f;
                if (!float.TryParse(e.GetArg("quantity"), out quantity))
                {
                    quantity = 1.0f;
                }

                int       fromCode, toCode = 0;
                UnitTable table = null;
                ResolveUnitCodes(from, to, out table, out fromCode, out toCode);

                if (table != null)
                {
                    Unit inUnit  = new Unit(fromCode, quantity, table);
                    Unit outUnit = inUnit.Convert(toCode);
                    await e.Channel.SendMessage(inUnit.ToString() + " = " + outUnit.ToString()).ConfigureAwait(false);
                }
                else
                {
                    CultureInfo ci = new CultureInfo("en-US");
                    Thread.CurrentThread.CurrentCulture = ci;
                    reInitCurrencyConverterTable();
                    Unit inUnit  = currTable.CreateUnit(quantity, from.ToUpperInvariant());
                    Unit outUnit = inUnit.Convert(currTable.CurrencyCode(to.ToUpperInvariant()));
                    await e.Channel.SendMessage(inUnit.ToString() + " = " + outUnit.ToString()).ConfigureAwait(false);
                }
            }
            catch     //(Exception ex)
            {
                //Console.WriteLine(ex.ToString());
                await e.Channel.SendMessage("Bad input format, or sth went wrong... Try to list them with `" + Module.Prefix + "`convertlist").ConfigureAwait(false);
            }
        };
コード例 #10
0
        public JsonResult GetSaleOrderDetailJson(int SaleOrderLineId)
        {
            var temp = (from L in db.ViewSaleOrderBalance
                        join Dl in db.SaleOrderLine on L.SaleOrderLineId equals Dl.SaleOrderLineId into SaleOrderLineTable
                        from SaleOrderLineTab in SaleOrderLineTable.DefaultIfEmpty()
                        join P in db.Product on L.ProductId equals P.ProductId into ProductTable
                        from ProductTab in ProductTable.DefaultIfEmpty()
                        join U in db.Units on ProductTab.UnitId equals U.UnitId into UnitTable
                        from UnitTab in UnitTable.DefaultIfEmpty()
                        join D1 in db.Dimension1 on L.Dimension1Id equals D1.Dimension1Id into Dimension1Table
                        from Dimension1Tab in Dimension1Table.DefaultIfEmpty()
                        join D2 in db.Dimension2 on L.Dimension2Id equals D2.Dimension2Id into Dimension2Table
                        from Dimension2Tab in Dimension2Table.DefaultIfEmpty()
                        where L.SaleOrderLineId == SaleOrderLineId
                        select new
            {
                SaleOrderHeaderDocNo = L.SaleOrderNo,
                UnitId = UnitTab.UnitId,
                UnitName = UnitTab.UnitName,
                DealUnitId = SaleOrderLineTab.DealUnitId,
                Specification = SaleOrderLineTab.Specification,
                UnitConversionMultiplier = SaleOrderLineTab.UnitConversionMultiplier,
                ProductId = L.ProductId,
                Dimension1Id = L.Dimension1Id,
                Dimension1Name = Dimension1Tab.Dimension1Name,
                Dimension2Id = L.Dimension2Id,
                Dimension2Name = Dimension2Tab.Dimension2Name,
                Rate = L.Rate,
                BalanceQty = L.BalanceQty
            }).FirstOrDefault();

            if (temp != null)
            {
                return(Json(temp));
            }
            else
            {
                return(null);
            }
        }
コード例 #11
0
ファイル: UnitController.cs プロジェクト: ZhaoAndQian/CoreApi
 public IActionResult Add([FromBody] UnitTable _unit)
 {
     try
     {
         //return Ok(_repository.SaveGetId(_unit));
         int id = _repository.SaveGetId(_unit);
         return(Json(new
         {
             id,
             state = "0",
             msg = "添加成功!"
         }));
     }
     catch (Exception ex)
     {
         return(Json(new
         {
             state = "-1",
             msg = "非法操作!"
         }));
     }
 }
コード例 #12
0
 public bool GetUnitTable(int a_nID, out UnitTable a_refTb)
 {
     return(m_mapUnitTb.TryGetValue(a_nID, out a_refTb));
 }
        public UnitViewModel()
        {
            Descriptions = null;
            ListUnit     = new List <UnitTable>(DataProvider.Ins.Entities.UnitTable);

            LoadEditCommand = new RelayCommand <object>((p) => { return(true); }, (p) => { LoadDialogAccountEdit(); });

            AddCommand = new RelayCommand <object>((p) =>
            {
                var Unit = DataProvider.Ins.Entities.UnitTable.Where(x => x.Descriptions == Descriptions);

                if (string.IsNullOrEmpty(Descriptions))
                {
                    return(false);
                }

                if (Unit.Count() != 0 || Unit == null)
                {
                    return(false);
                }

                return(true);
            }, (p) =>
            {
                var newUnit          = new UnitTable();
                newUnit.Descriptions = Descriptions;

                DataProvider.Ins.Entities.UnitTable.Add(newUnit);
                DataProvider.Ins.Entities.SaveChanges();
                ListUnit = new List <UnitTable>(DataProvider.Ins.Entities.UnitTable);

                Descriptions  = null;
                SelectedItems = null;

                IsActiveSnackBar = true;
                Message          = "Thêm Thành Công!";

                System.Timers.Timer timer = new System.Timers.Timer();
                timer.Interval            = 3000;
                timer.Enabled             = true;
                timer.Elapsed            += ShowSnackBar;
                timer.Start();
            });

            EditCommand = new RelayCommand <object>((p) =>
            {
                var Unit = DataProvider.Ins.Entities.UnitTable.Where(x => x.Descriptions == Descriptions);

                if (string.IsNullOrEmpty(Descriptions))
                {
                    return(false);
                }

                if (Unit == null || SelectedItems == null)
                {
                    return(false);
                }

                return(true);
            }, (p) =>
            {
                UnitTable EditItem = DataProvider.Ins.Entities.UnitTable.Where(x => x.ID == SelectedItems.ID).SingleOrDefault();
                if (EditItem == null)
                {
                    return;
                }
                EditItem.Descriptions = Descriptions;

                DataProvider.Ins.Entities.SaveChanges();
                ListUnit = new List <UnitTable>(DataProvider.Ins.Entities.UnitTable);

                Descriptions  = null;
                SelectedItems = null;

                IsActiveSnackBar = true;
                Message          = "Sửa Thành Công!";

                System.Timers.Timer timer = new System.Timers.Timer();
                timer.Interval            = 3000;
                timer.Enabled             = true;
                timer.Elapsed            += ShowSnackBar;
                timer.Start();
            });

            DeleteCommand = new RelayCommand <object>((p) =>
            {
                var Unit = DataProvider.Ins.Entities.UnitTable.Where(x => x.Descriptions == Descriptions);

                if (string.IsNullOrEmpty(Descriptions))
                {
                    return(false);
                }

                if (Unit == null || SelectedItems == null)
                {
                    return(false);
                }

                return(true);
            }, (p) =>
            {
                UnitTable DeleteItem = DataProvider.Ins.Entities.UnitTable.Where(x => x.ID == SelectedItems.ID).SingleOrDefault();

                var listProduct = DataProvider.Ins.Entities.ProductTable.Where(x => x.ID_Unit == SelectedItems.ID);

                if (DeleteItem == null)
                {
                    return;
                }

                if (listProduct.Count() > 0)
                {
                    SelectedItems = null;
                    LoadDialogErrorDelete();
                    return;
                }

                DataProvider.Ins.Entities.UnitTable.Remove(DeleteItem);
                DataProvider.Ins.Entities.SaveChanges();

                ListUnit = new List <UnitTable>(DataProvider.Ins.Entities.UnitTable);

                Descriptions  = null;
                SelectedItems = null;

                IsActiveSnackBar = true;
                Message          = "Xóa Thành Công!";

                System.Timers.Timer timer = new System.Timers.Timer();
                timer.Interval            = 3000;
                timer.Enabled             = true;
                timer.Elapsed            += ShowSnackBar;
                timer.Start();
            });

            SearchCommand = new RelayCommand <object>((p) =>
            {
                return(true);
            },
                                                      (p) =>
            {
                if (SearchTerm == null)
                {
                    return;
                }

                ListUnit = new List <UnitTable>(DataProvider.Ins.Entities.UnitTable.Where(
                                                    x => x.Descriptions.ToLower().Contains(SearchTerm)));
            });
        }
コード例 #14
0
 public void ApplyUnitTb(UnitTable a_refTb)
 {
     m_nPow = a_refTb.m_nPow;
     m_nDef = a_refTb.m_nDef;
     m_nHP  = a_refTb.m_nHP;
 }
コード例 #15
0
 private int LookupUnit(UnitTable table, string lookup)
 {
     string wellformedLookup = lookup.ToLowerInvariant().Replace("°", "");
     int i = 1;
     while (table.IsKnownUnit(i))
     {
         if (wellformedLookup == table.GetUnitName(i).ToLowerInvariant().Replace("°", "") ||
             wellformedLookup == table.GetUnitPlural(i).ToLowerInvariant().Replace("°", "") ||
             wellformedLookup == table.GetUnitSymbol(i).ToLowerInvariant().Replace("°", ""))
         {
             return i;
         }
         i++;
     }
     return 0;
 }
コード例 #16
0
 private void ResolveUnitCodes(string from, string to, out UnitTable table, out int fromCode, out int toCode)
 {
     foreach (var tmpTable in unitTables)
     {
         int f = LookupUnit(tmpTable, from);
         int t = LookupUnit(tmpTable, to);
         if (f > 0 && t > 0)
         {
             table = tmpTable;
             fromCode = f;
             toCode = t;
             return;
         }
     }
     table = null;
     fromCode = 0;
     toCode = 0;
 }
コード例 #17
0
		public UnitGroup()
		{
			m_Units = new UnitTable();
		}
コード例 #18
0
 /// <summary>
 /// Adds the necessary indexes to the tables.
 /// </summary>
 private void AddIndexes()
 {
     FormatTable.AddIndex("Code");
     QuantityTable.AddIndex("Code");
     UnitTable.AddIndex("Code");
 }
コード例 #19
0
        private void AddRows()
        {
            ISQLiteRow knightSpearmanStats = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 1
            ISQLiteRow knightFootmanStats  = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 2
            ISQLiteRow knightArcherStats   = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 3
            ISQLiteRow knightWorkerStats   = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 4

            ISQLiteRow vikingSpearmanStats = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 5
            ISQLiteRow vikingFootmanStats  = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 6
            ISQLiteRow vikingArcherStats   = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 7
            ISQLiteRow vikingWorkerStats   = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 10, 10, 10, 10, 5f, 100, 10, 2, 150f, 10, 10, 150f, 50)); // -- 8

            ISQLiteRow knightFaction  = FactionTable.Insert(new SQLiteFactionModel(FactionTable, EFaction.Knights.ToString()));                           // -- 1
            ISQLiteRow vikingsFaction = FactionTable.Insert(new SQLiteFactionModel(FactionTable, EFaction.Vikings.ToString()));                           // -- 2

            SQLiteUnitModel knightSpearmanUnit = new SQLiteUnitModel(UnitTable, knightFaction.Id, (int)EUnitType.Spearman, 0, knightSpearmanStats.Id, "Spearman");
            SQLiteUnitModel knightFootmanUnit  = new SQLiteUnitModel(UnitTable, knightFaction.Id, (int)EUnitType.Footman, 0, knightFootmanStats.Id, "Footman");
            SQLiteUnitModel knightArcherUnit   = new SQLiteUnitModel(UnitTable, knightFaction.Id, (int)EUnitType.Bowman, 0, knightArcherStats.Id, "Bowman");
            SQLiteUnitModel knightWorkerUnit   = new SQLiteUnitModel(UnitTable, knightFaction.Id, (int)EUnitType.Worker, 0, knightWorkerStats.Id, "Worker");

            SQLiteUnitModel vikingSpearmanUnit = new SQLiteUnitModel(UnitTable, vikingsFaction.Id, (int)EUnitType.Spearman, 0, vikingSpearmanStats.Id, "Spearman");
            SQLiteUnitModel vikingFootmanUnit  = new SQLiteUnitModel(UnitTable, vikingsFaction.Id, (int)EUnitType.Footman, 0, vikingFootmanStats.Id, "Footman");
            SQLiteUnitModel vikingArcherUnit   = new SQLiteUnitModel(UnitTable, vikingsFaction.Id, (int)EUnitType.Bowman, 0, vikingArcherStats.Id, "Bowman");
            SQLiteUnitModel vikingWorkerUnit   = new SQLiteUnitModel(UnitTable, vikingsFaction.Id, (int)EUnitType.Worker, 0, vikingWorkerStats.Id, "Worker");


            UnitTable.Insert(knightSpearmanUnit);                                                                                                               // -- 1
            UnitTable.Insert(knightFootmanUnit);                                                                                                                // -- 2
            UnitTable.Insert(knightArcherUnit);                                                                                                                 // -- 3
            UnitTable.Insert(knightWorkerUnit);                                                                                                                 // -- 4

            UnitTable.Insert(vikingSpearmanUnit);                                                                                                               // -- 5
            UnitTable.Insert(vikingFootmanUnit);                                                                                                                // -- 6
            UnitTable.Insert(vikingArcherUnit);                                                                                                                 // -- 7
            UnitTable.Insert(vikingWorkerUnit);                                                                                                                 // -- 8

            ISQLiteRow vikingArcheryRangeStats     = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 9
            ISQLiteRow vikingBarracksStats         = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 10
            ISQLiteRow vikingBlacksmithStats       = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 11
            ISQLiteRow vikingFieldStats            = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 12
            ISQLiteRow vikingGatheringStationStats = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 13
            ISQLiteRow vikingTowerStats            = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 250, 125, 50, 10, 5f, 400, 40, 2, 0f, 10, 10, 0f, 50)); // -- 14
            ISQLiteRow vikingTownHallStats         = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 15

            ISQLiteRow knightArcheryRangeStats     = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 9
            ISQLiteRow knightBarracksStats         = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 10
            ISQLiteRow knightBlacksmithStats       = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 11
            ISQLiteRow knightFieldStats            = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 12
            ISQLiteRow knightGatheringStationStats = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 13
            ISQLiteRow knightTowerStats            = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 250, 125, 50, 10, 5f, 400, 40, 2, 0f, 10, 10, 0f, 50)); // -- 14
            ISQLiteRow knightTownHallStats         = StatsTable.Insert(new SQLiteStatsModel(StatsTable, 500, 250, 100, 10, 5f, 800, 0, 2, 0f, 10, 10, 0f, 50)); // -- 15

            SQLiteBuildingModel vikingArcheryRangeBuilding     = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.ArcheryRange, 0, vikingArcheryRangeStats.Id, "ArcheryRange");
            SQLiteBuildingModel vikingBarracksBuilding         = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.Barracks, 0, vikingBarracksStats.Id, "Barracks");
            SQLiteBuildingModel vikingBlacksmithBuilding       = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.Blacksmith, 0, vikingBlacksmithStats.Id, "Blacksmith");
            SQLiteBuildingModel vikingFieldBuilding            = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.Field, 0, vikingFieldStats.Id, "Field");
            SQLiteBuildingModel vikingGatheringStationBuilding = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.GatheringStation, 0, vikingGatheringStationStats.Id, "GatheringStation");
            SQLiteBuildingModel vikingTowerBuilding            = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.Tower, 0, vikingTowerStats.Id, "Tower");
            SQLiteBuildingModel vikingTownHallBuilding         = new SQLiteBuildingModel(BuildingTable, vikingsFaction.Id, (int)EBuildingType.TownHall, 0, vikingTownHallStats.Id, "TownHall");

            SQLiteBuildingModel knightArcheryRangeBuilding     = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.ArcheryRange, 0, knightArcheryRangeStats.Id, "ArcheryRange");
            SQLiteBuildingModel knightBarracksBuilding         = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.Barracks, 0, knightBarracksStats.Id, "Barracks");
            SQLiteBuildingModel knightBlacksmithBuilding       = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.Blacksmith, 0, knightBlacksmithStats.Id, "Blacksmith");
            SQLiteBuildingModel knightFieldBuilding            = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.Field, 0, knightFieldStats.Id, "Field");
            SQLiteBuildingModel knightGatheringStationBuilding = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.GatheringStation, 0, knightGatheringStationStats.Id, "GatheringStation");
            SQLiteBuildingModel knightTowerBuilding            = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.Tower, 0, knightTowerStats.Id, "Tower");
            SQLiteBuildingModel knightTownHallBuilding         = new SQLiteBuildingModel(BuildingTable, knightFaction.Id, (int)EBuildingType.TownHall, 0, knightTownHallStats.Id, "TownHall");

            BuildingTable.Insert(vikingArcheryRangeBuilding);     // -- 1
            BuildingTable.Insert(vikingBarracksBuilding);         // -- 2
            BuildingTable.Insert(vikingBlacksmithBuilding);       // -- 3
            BuildingTable.Insert(vikingFieldBuilding);            // -- 4
            BuildingTable.Insert(vikingGatheringStationBuilding); // -- 5
            BuildingTable.Insert(vikingTowerBuilding);            // -- 6
            BuildingTable.Insert(vikingTownHallBuilding);         // -- 7

            BuildingTable.Insert(knightArcheryRangeBuilding);     // -- 8
            BuildingTable.Insert(knightBarracksBuilding);         // -- 9
            BuildingTable.Insert(knightBlacksmithBuilding);       // -- 10
            BuildingTable.Insert(knightFieldBuilding);            // -- 11
            BuildingTable.Insert(knightGatheringStationBuilding); // -- 12
            BuildingTable.Insert(knightTowerBuilding);            // -- 13
            BuildingTable.Insert(knightTownHallBuilding);         // -- 14
        }