Example #1
0
        /// <summary>
        /// Draws all horizontal or vertical continent lines (and province lines if required).
        /// </summary>
        /// <remarks>
        /// For horizontal lines: map/gameXXX params are the VERTICAL coordinates. otherMap/gameXXX are then the horizontals.
        /// For vertical lines: map/gameXXX params are the HORIZONTAL coordinates.
        /// </remarks>
        private void DrawContinentLines(int mapMin, int mapMax, int gameMin, int gameMax, int villageSize, bool isHorizontal, int otherMapMin, int otherMapMax, int otherGameMin, int otherGameMax, int otherVillageSize)
        {
            const int provinceWidth  = 5;
            const int continentWidth = 100;

            if (_villageWidthSpacing > 4 && _settings.ProvinceLines)
            {
                using (var provincePen = _settings.CreateProvincePen())
                {
                    DrawContinentLines(provincePen, mapMin, mapMax, gameMin, gameMax, villageSize, isHorizontal, provinceWidth, otherMapMin, otherMapMax, otherGameMin, otherGameMax, otherVillageSize);
                }
            }

            if (_settings.ContinentLines)
            {
                using (var continentPen = _settings.CreateContinentPen())
                {
                    DrawContinentLines(continentPen, mapMin, mapMax, gameMin, gameMax, villageSize, isHorizontal, continentWidth, otherMapMin, otherMapMax, otherGameMin, otherGameMax, otherVillageSize);
                }
            }
        }