public ContinentLinesPainter(Graphics g, DisplaySettings settings, VillageDimensions dimensions, Rectangle gameRectangle, Rectangle mapSize) { _settings = settings; _g = g; _visibleGameRectangle = gameRectangle; _toPaint = mapSize; _villageWidthSpacing = dimensions.SizeWithSpacing.Width; _villageHeightSpacing = dimensions.SizeWithSpacing.Height; }
public Display(DisplaySettings settings, bool isMiniMap, Map map, ref Location location) : this(settings, map) { // Validate zoom or we have a potential divide by zero etc if (isMiniMap) { ZoomInfo zoom = DrawerFactoryBase.CreateMiniMapZoom(location.Zoom); location = zoom.Validate(location); _drawerFactoryStrategy = DrawerFactoryBase.CreateMiniMap(location.Zoom); } else { ZoomInfo zoom = DrawerFactoryBase.CreateZoom(location.Display, location.Zoom); location = ValidateZoom(zoom, location); _drawerFactoryStrategy = DrawerFactoryBase.Create(location.Display, location.Zoom, settings.Scenery); } // TODO: make this lazy. Setting here = crash // Is fixed by calling UpdateLocation after Map.Location is set //_visibleRectangle = GetGameRectangle(); }
private Display(DisplaySettings settings, Map map) { _settings = settings; _map = map; _markers = map.MarkerManager; }