void AddCircles(IList circles) { var map = NativeMap; if (map == null) { return; } if (_circles == null) { _circles = new List <ACircle>(); } _circles.AddRange(circles.Cast <Circle>().Select(circle => { var opts = new CircleOptions(); opts.InvokeCenter(new LatLng(circle.Center.Latitude, circle.Center.Longitude)); opts.InvokeRadius(circle.Radius.Meters); opts.InvokeStrokeWidth(circle.StrokeWidth * _scaledDensity); // TODO: convert from px to pt. Is this collect? (looks like same iOS Maps) opts.InvokeStrokeColor(circle.StrokeColor.ToAndroid()); opts.InvokeFillColor(circle.FillColor.ToAndroid()); //opts.Clickable(circle.IsClickable); var nativeCircle = map.AddCircle(opts); // associate pin with marker for later lookup in event handlers circle.Id = nativeCircle; return(nativeCircle); })); }
// TODO: Step 4c - handle info popup tap private void HandleInfoWindowClick(object sender, GoogleMap.InfoWindowClickEventArgs e) { // Draw a circle on the map var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(Location_NewYork); circleOptions.InvokeRadius(100000.0); circleOptions.InvokeFillColor(Android.Graphics.Color.Argb(150, 59, 153, 212)); circleOptions.InvokeStrokeColor(Android.Graphics.Color.Rgb(159, 153, 212)); circleOptions.InvokeStrokeWidth(2); _map.AddCircle(circleOptions); // Draw a polygon (Wyoming) on the map var polygonOptions = new PolygonOptions(); polygonOptions.Add(new LatLng[] { new LatLng(45.00, -111.00), new LatLng(45, -104), new LatLng(41, -104), new LatLng(41, -111) }); polygonOptions.InvokeFillColor(Android.Graphics.Color.Argb(150, 21, 48, 78)); polygonOptions.InvokeStrokeColor(Android.Graphics.Color.Rgb(21, 48, 78)); polygonOptions.InvokeStrokeWidth(2); _map.AddPolygon(polygonOptions); }
private void CircleDemo(HuaweiMap hMap) { hMap.Clear(); Circle circle1; LatLng circle1LatLng = new LatLng(41.01019, 28.974475); CircleOptions circle1Options = new CircleOptions(); circle1Options.InvokeCenter(circle1LatLng); circle1Options.InvokeRadius(1600); circle1Options.InvokeStrokeWidth(5); circle1Options.InvokeStrokeColor(Color.Blue); circle1Options.InvokeFillColor(Color.Argb(60, 0, 0, 255)); circle1Options.Clickable(true); circle1Options.InvokeZIndex(2); circle1 = hMap.AddCircle(circle1Options); Circle circle2; LatLng circle2LatLng = new LatLng(41.01563, 29.052667); CircleOptions circle2Options = new CircleOptions(); circle2Options.InvokeCenter(circle2LatLng); circle2Options.InvokeRadius(5000); circle2Options.InvokeStrokeWidth(10); circle2Options.InvokeStrokeColor(Color.OrangeRed); circle2Options.InvokeFillColor(Color.Argb(60, 255, 200, 0)); circle2Options.Clickable(true); circle2Options.InvokeZIndex(1); circle2 = hMap.AddCircle(circle2Options); }
public void OnLocationChanged(Location location) { Location currentLocation = location; myLocation = location; if (currentLocation == null) { Console.WriteLine("Unable to determine your location. Try again in a short while."); } else { Console.WriteLine(string.Format("{0:f6},{1:f6}", currentLocation.Latitude, currentLocation.Longitude)); myLocation = location; if (positionMarker != null) { positionMarker.Remove(); } var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(location.Latitude, location.Longitude)); circleOptions.InvokeRadius(20); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); //positionMarker = mMap.AddCircle(circleOptions); } }
public void updateCircle() { CustomMap customMap = (CustomMap)this.Element; if (customMap != null) { if (customMap.UserPin != null) { if (circle != null) { circle.Remove(); circle.Dispose(); } //moy CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(customMap.UserPin.Position.Latitude, customMap.UserPin.Position.Longitude)); circleOptions.InvokeRadius(customMap.getDistanceUserTarget()); circleOptions.InvokeFillColor(Android.Graphics.Color.Argb(0, 0, 0, 0)); circleOptions.InvokeStrokeColor(Android.Graphics.Color.Argb(240, 250, 250, 250)); circleOptions.InvokeStrokeWidth(5f); circle = map.AddCircle(circleOptions); } } }
protected override void OnMapReady(GoogleMap map) { base.OnMapReady(map); var polylineOptions = new PolylineOptions(); polylineOptions.InvokeColor(0x702418ff); foreach (var position in routeCoordinates) { polylineOptions.Add(new LatLng(position.Latitude, position.Longitude)); } NativeMap.AddPolyline(polylineOptions); foreach (Bus bus in BusList.busList) { if (bus.route == "blue") { CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(bus.lat, bus.lng)); circleOptions.InvokeRadius(30); circleOptions.InvokeFillColor(0X700000ff); circleOptions.InvokeStrokeColor(0X70FFFFFF); circleOptions.InvokeStrokeWidth(5); NativeMap.AddCircle(circleOptions); } } }
public void OnMapReady(GoogleMap googleMap) { map = googleMap; if (!isCircle) { var polylineOptions = new PolylineOptions(); polylineOptions.InvokeColor(0x66FF0000); foreach (var position in routeCoordinates) { polylineOptions.Add(new LatLng(position.Latitude, position.Longitude)); } map.AddPolyline(polylineOptions); } if (isCircle) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(circle.Position.Latitude, circle.Position.Longitude)); circleOptions.InvokeRadius(circle.Radius); circleOptions.InvokeFillColor(0X00FFFFFF); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(3); map.AddCircle(circleOptions); } }
protected override MarkerOptions CreateMarker(Pin pin) { if (pin is CirclePin) { //create an overlay circle, and add to map var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(pin.Position.Latitude, pin.Position.Longitude)); circleOptions.InvokeRadius(PublishedData.PinOverlayRadius); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); Circle circle = NativeMap.AddCircle(circleOptions); (pin as CirclePin).Overlay = circle; } // marker,or pin. var marker = new MarkerOptions(); marker.SetPosition(new LatLng(pin.Position.Latitude, pin.Position.Longitude)); marker.Anchor(0.5f, 0.5f);// set anchor to to middle of icon marker.SetTitle(pin.Label); marker.SetSnippet(pin.Address); Bitmap imageBitmap = BitmapFactory.DecodeResource(Resources, Resource.Drawable.pin); Bitmap resizedIcon = Bitmap.CreateScaledBitmap(imageBitmap, 50, 50, false); marker.SetIcon(BitmapDescriptorFactory.FromBitmap(resizedIcon)); return(marker); }
protected override MarkerOptions CreateMarker(Pin pin) { CustomPin customPin = (CustomPin)pin; var marker = new MarkerOptions(); marker.SetPosition(new LatLng(pin.Position.Latitude, pin.Position.Longitude)); marker.SetAlpha(0); var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(customPin.Position.Latitude, customPin.Position.Longitude)); circleOptions.InvokeRadius(1000); circleOptions.InvokeStrokeWidth(0); switch (customPin.Status) { case StatusEnum.Diagnosed: circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); NativeMap.AddCircle(circleOptions); break; case StatusEnum.Healthy: break; case StatusEnum.Recovered: break; case StatusEnum.Symptomatic: circleOptions.InvokeFillColor(0X33FF4D26); circleOptions.InvokeStrokeColor(0X33FF4D26); NativeMap.AddCircle(circleOptions); break; default: break; } /* circleOptions.InvokeFillColor(0X66FF0000); * circleOptions.InvokeStrokeColor(0X66FF0000);*/ return(marker); }
private void DrawCircle() { CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(30.679879, 104.064855)); circleOptions.InvokeRadius(9000); circleOptions.InvokeStrokeColor(Color.Black); circleOptions.InvokeFillColor(Color.Transparent); circleOptions.InvokeStrokeWidth(3); aMap.AddCircle(circleOptions); }
void Android.Gms.Location.ILocationListener.OnLocationChanged(Location location) { double lat, lng; lat = location.Latitude; lng = location.Longitude; TextView search_txt = FindViewById <TextView>(Resource.Id.search_txt); mCurrentLocation = location; UpdateUI(); mMap.Clear(); LatLng mGoogleApiClient = new LatLng(lat, lng); CameraPosition.Builder builder = CameraPosition.InvokeBuilder(); builder.Target(mGoogleApiClient); builder.Zoom(14); CameraPosition cameraPosition = builder.Build(); CameraUpdate cameraUpdate = CameraUpdateFactory.NewCameraPosition(cameraPosition); if (mMap != null) { mMap.AnimateCamera(CameraUpdateFactory.NewCameraPosition(cameraPosition)); } Log.Debug(GetType().FullName, "OnLocationChanged = - Adresse" + " " + search_txt.Text + " " + lat + " " + lng); CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(lat, lng)); circleOptions.InvokeRadius(200); // RAYON DU CERCLE circleOptions.InvokeStrokeWidth(4); // EPAISSEUR DU TRIT DU CERCLE circleOptions.InvokeStrokeColor(Android.Graphics.Color.ParseColor("#75C043")); // Cercle Couleur Circle newCircle = mMap.AddCircle(circleOptions); newCircle.Visible = true; string URL_GetTaxis = "GetTaxis"; Dictionary <string, string> parameters = new Dictionary <string, string>(); parameters.Add("lat", lat.ToString().Replace(',', '.')); parameters.Add("longi", lng.ToString().Replace(',', '.')); var JsonRetour = taxisController.POST(URL_GetTaxis, parameters); var retour = JsonConvert.DeserializeObject <ReturnData>(JsonRetour); for (int i = 0; i < retour.Data.taxiData.Length; i++) { var marker = new MarkerOptions() .SetPosition(new LatLng((double)retour.Data.taxiData[i].Position.Lat, (double)retour.Data.taxiData[i].Position.Lon)) .Anchor(0.5f, 0.5f) .SetIcon(BitmapDescriptorFactory.FromResource(Resource.Mipmap.marker_taxi)) .SetTitle(search_txt.Text); mMap.AddMarker(marker); } }
public void OnMapLoaded(GoogleMap googleMap) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(this.circle.Position.Latitude, this.circle.Position.Longitude)); circleOptions.InvokeRadius(this.circle.Radius); //circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(3); map.AddCircle(circleOptions); }
public void OnMapReady(GoogleMap googleMap) { map = googleMap; var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(circle.Position.Latitude, circle.Position.Longitude)); circleOptions.InvokeRadius(circle.Radius); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); map.AddCircle(circleOptions); }
private void DrawBlueDot() { CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(currentLocation.Latitude, currentLocation.Longitude)); circleOptions.InvokeRadius(5); circleOptions.InvokeFillColor(Color.CadetBlue); circleOptions.InvokeStrokeColor(Color.White); circleOptions.InvokeStrokeWidth(2); circleOptions.InvokeZIndex(1); blueDot = _map.AddCircle(circleOptions); }
protected override void OnCreate(Bundle savedInstanceState) { RequestWindowFeature(WindowFeatures.NoTitle); base.OnCreate(savedInstanceState); SetContentView(Resource.Layout.SearchJourney); #region setup map markers currentLocation = new MarkerOptions(); currentLocation.SetTitle("Current Position"); currentLocation.SetIcon(BitmapDescriptorFactory.DefaultMarker(BitmapDescriptorFactory.HueBlue)); currentLocation.SetPosition(getCurrentPosition()); currentLocation.Visible(false); fromLocation = new MarkerOptions(); fromLocation.SetTitle("From Here"); fromLocation.SetIcon(BitmapDescriptorFactory.DefaultMarker(BitmapDescriptorFactory.HueRed)); fromLocation.SetPosition(getCurrentPosition()); fromLocation.Visible(false); toLocation = new MarkerOptions(); toLocation.SetTitle("To Here"); toLocation.SetIcon(BitmapDescriptorFactory.DefaultMarker(BitmapDescriptorFactory.HueGreen)); toLocation.SetPosition(getCurrentPosition()); toLocation.Visible(false); fromCircleOp = new CircleOptions(); fromCircleOp.InvokeCenter(getCurrentPosition()); fromCircleOp.InvokeRadius(1000); fromCircleOp.InvokeFillColor(0X66FF0000); fromCircleOp.InvokeStrokeColor(0X66FF0000); fromCircleOp.InvokeStrokeWidth(0); fromCircleOp.Visible(false); toCircleOp = new CircleOptions(); toCircleOp.InvokeCenter(getCurrentPosition()); toCircleOp.InvokeRadius(1000); toCircleOp.InvokeFillColor(Color.Green); toCircleOp.InvokeStrokeColor(Color.Green); toCircleOp.InvokeStrokeWidth(0); toCircleOp.Visible(false); #endregion // Create your application here InitMapFragment(); SetupCurrentLocationButton(); SetupSearchButton(); SetupSetFromButton(); SetupSetToButton(); SetupForm(); }
protected override void OnMapReady(Android.Gms.Maps.GoogleMap map) { base.OnMapReady(map); var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(circle.Position.Latitude, circle.Position.Longitude)); circleOptions.InvokeRadius(circle.Radius); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); NativeMap.AddCircle(circleOptions); }
protected virtual CircleOptions CreateCircleOptions(Circle circle) { var opts = new CircleOptions() .InvokeCenter(new LatLng(circle.Center.Latitude, circle.Center.Longitude)) .InvokeRadius(circle.Radius.Meters) .InvokeStrokeWidth(circle.StrokeWidth); if (!circle.StrokeColor.IsDefault) opts.InvokeStrokeColor(circle.StrokeColor.ToAndroid()); if (!circle.FillColor.IsDefault) opts.InvokeFillColor(circle.FillColor.ToAndroid()); return opts; }
/// <summary> /// Adds a bubble that reflects the expiry range of a helicopter carrying organ /// </summary> /// <param name="heliPin"></param> private void addOrganRange(CustomPin heliPin) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(heliPin.Position.Latitude, heliPin.Position.Longitude)); // TODO adjust to organ countdown circleOptions.InvokeRadius(40000); circleOptions.InvokeFillColor(0X660000FF); circleOptions.InvokeStrokeColor(0X660000FF); circleOptions.InvokeStrokeWidth(0); highlightedOrganRange = new Tuple <CustomPin, Circle>(heliPin, NativeMap.AddCircle(circleOptions)); }
public void CreateCircle(Circle circle) { if (circle == null) { return; } var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(circle.Position.Latitude, circle.Position.Longitude)); circleOptions.InvokeRadius(circle.Radius); circleOptions.InvokeFillColor(0X00FFFFFF); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(3); map.AddCircle(circleOptions); }
void updateMap() { _map.Clear(); MarkerOptions marker1 = new MarkerOptions(); marker1.SetPosition(newLocation); _map.AddMarker(marker1); CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(newLocation); circleOptions.InvokeRadius(radius); circleOptions.InvokeFillColor(Convert.ToInt32("0x3000ffff", 16)); circleOptions.InvokeStrokeColor(Convert.ToInt32("0x3000ffff", 16)); _circle = _map.AddCircle(circleOptions); }
/// <summary> /// Minulí pozice zůstávají na mapě /// </summary> private void DrawDebugPosition() { if (debugPositionCircle != null) { debugPositionCircle.Dispose(); } debugPositionCircle = new CircleOptions(); debugPositionCircle.InvokeCenter(new LatLng(customMap.DebugPosition.Latitude, customMap.DebugPosition.Longitude)); debugPositionCircle.InvokeRadius(50); debugPositionCircle.InvokeFillColor(0X66FF0000); debugPositionCircle.InvokeStrokeColor(0X66FF0000); debugPositionCircle.InvokeStrokeWidth(0); NativeMap.AddCircle(debugPositionCircle); }
public void DrawCircle(GoogleMap gMap) { Circle circle; var CircleMaker = new CircleOptions(); var latlong = new LatLng(13.0291, 80.2083); //Location CircleMaker.InvokeCenter(latlong); // CircleMaker.InvokeRadius(1000); //Radius in Circle CircleMaker.InvokeStrokeWidth(4); CircleMaker.InvokeStrokeColor(Android.Graphics.Color.ParseColor("#e6d9534f")); //Circle Color CircleMaker.InvokeFillColor(Color.Argb(034, 209, 72, 54)); CameraUpdate camera = CameraUpdateFactory.NewLatLngZoom(latlong, 15); //Map Zoom Level circle = GMap.AddCircle(CircleMaker); //Gmap Add Circle }
protected override void OnElementPropertyChanged(object sender, System.ComponentModel.PropertyChangedEventArgs e) { base.OnElementPropertyChanged(sender, e); if (e.PropertyName.Equals("VisibleRegion") && !isDrawn) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(circle.Position.Latitude, circle.Position.Longitude)); circleOptions.InvokeRadius(circle.Radius); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); NativeMap.AddCircle(circleOptions); isDrawn = true; } }
protected override NativeCircle CreateNativeItem(Circle outerItem) { var opts = new CircleOptions(); opts.InvokeCenter(new LatLng(outerItem.Center.Latitude, outerItem.Center.Longitude)); opts.InvokeRadius(outerItem.Radius.Meters); opts.InvokeStrokeWidth(outerItem.StrokeWidth * this.ScaledDensity); // TODO: convert from px to pt. Is this collect? (looks like same iOS Maps) opts.InvokeStrokeColor(outerItem.StrokeColor.ToAndroid()); opts.InvokeFillColor(outerItem.FillColor.ToAndroid()); opts.Clickable(outerItem.IsClickable); var nativeCircle = NativeMap.AddCircle(opts); // associate pin with marker for later lookup in event handlers outerItem.NativeObject = nativeCircle; return(nativeCircle); }
/// <summary> /// When the user stops. /// </summary> /// <param name="sender">Sender object</param> /// <param name="e">User's position</param> private void Model_UserStopped(object sender, PositionArgs e) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(e.LocationData.Latitude, e.LocationData.Longitude)); circleOptions.InvokeRadius(14); circleOptions.InvokeFillColor(Color.Rgb(213, 52, 58)); circleOptions.InvokeStrokeColor(Color.Black); circleOptions.InvokeStrokeWidth(1); circleOptions.InvokeZIndex(10); RunOnUiThread(() => { _map.AddCircle(circleOptions); _speedTextView.Text = "0"; }); }
private void UpdateCircles() { circles?.ForEach(x => x.Remove()); circles = new List <Circle>(); customPins?.ForEach(x => { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(x.Position.Latitude, x.Position.Longitude)); circleOptions.InvokeRadius(x.Radius); circleOptions.InvokeFillColor(0X66FF0000); circleOptions.InvokeStrokeColor(0X66FF0000); circleOptions.InvokeStrokeWidth(0); circles.Add(NativeMap.AddCircle(circleOptions)); }); }
private void drawCircle() { Circle circle; LatLng circleLatLng = new LatLng(40.985996056, 29.035333192); CircleOptions circleOptions = new CircleOptions(); circle = hMap.AddCircle(circleOptions); circleOptions.InvokeCenter(circleLatLng); circleOptions.InvokeRadius(1800); circleOptions.InvokeStrokeWidth(5); circleOptions.InvokeStrokeColor(Color.Blue); circleOptions.InvokeStrokeWidth(30); circleOptions.Clickable(true); circleOptions.InvokeZIndex(2); circle = hMap.AddCircle(circleOptions); circleOptions.Clickable(true); hMap.CircleClick += OnCircleClick; }
/// <summary> /// Delete the previous user circle and draw the new one /// </summary> /// <param name="position">User's new position</param> private void DrawUser(LatLng position) { var circleOptions = new CircleOptions(); circleOptions.InvokeCenter(position); circleOptions.InvokeRadius(9); circleOptions.InvokeFillColor(Color.Rgb(69, 140, 228)); circleOptions.InvokeStrokeColor(Color.White); circleOptions.InvokeStrokeWidth(2); circleOptions.InvokeZIndex(11); RunOnUiThread(() => { var newUserPosition = _map.AddCircle(circleOptions); _userPosition?.Remove(); _userPosition = newUserPosition; }); }
public void OnMapReady(GoogleMap map) { mMap = map; mMap.MoveCamera(CameraUpdateFactory.NewLatLngZoom(new LatLng(latitude, longitude), 7)); var mapOptions = new MarkerOptions(); mapOptions.SetTitle("NOTAM"); mapOptions.SetPosition(new LatLng(latitude, longitude)); mMap.AddMarker(mapOptions); CircleOptions circleOptions = new CircleOptions(); circleOptions.InvokeCenter(new LatLng(latitude, longitude)); circleOptions.InvokeRadius(radius * 1852); circleOptions.InvokeStrokeColor(new ApplyTheme().GetColor(DesiredColor.RedTextWarning)); mMap.AddCircle(circleOptions); }
public MapOverlay(Cell cell) { CellID = cell.ID; // Set cell overlay options cellPolygonOptions = new PolygonOptions(); cellPolygonOptions.Add(new LatLng((double)cell.Latitude, (double)cell.Longitude)); //first rectangle point cellPolygonOptions.Add(new LatLng((double)cell.Latitude, (double)cell.Longitude + (double)GameModel.FrontierInterval)); cellPolygonOptions.Add(new LatLng((double)cell.Latitude + (double)GameModel.FrontierInterval, (double)cell.Longitude + (double)GameModel.FrontierInterval)); cellPolygonOptions.Add(new LatLng((double)cell.Latitude + (double)GameModel.FrontierInterval, (double)cell.Longitude)); //automatically connects last two points cellPolygonOptions.InvokeZIndex(100); // Set mine overlay options LatLng circleCenter = new LatLng((double)cell.Latitude + ((double)GameModel.FrontierInterval / 2), (double)cell.Longitude + ((double)GameModel.FrontierInterval / 2)); mineCircleOptions = new CircleOptions(); mineCircleOptions.InvokeCenter(circleCenter); mineCircleOptions.InvokeRadius(3); mineCircleOptions.InvokeStrokeWidth(6); mineCircleOptions.InvokeStrokeColor(Color.White); mineCircleOptions.InvokeZIndex(200); // Set antimine overlay options antiMineTriangleOptions = new PolygonOptions(); antiMineTriangleOptions.Add(new LatLng(((double)cell.Latitude + ((double)GameModel.FrontierInterval) * .75), ((double)cell.Longitude + (double)GameModel.FrontierInterval / 2))); antiMineTriangleOptions.Add(new LatLng(((double)cell.Latitude + ((double)GameModel.FrontierInterval) * .25), ((double)cell.Longitude + (double)GameModel.FrontierInterval * .25))); antiMineTriangleOptions.Add(new LatLng(((double)cell.Latitude + ((double)GameModel.FrontierInterval) * .25), ((double)cell.Longitude + (double)GameModel.FrontierInterval * .75))); antiMineTriangleOptions.InvokeStrokeWidth(6); antiMineTriangleOptions.InvokeStrokeColor(Color.White); antiMineTriangleOptions.InvokeZIndex(200); UpdateColor(cell.HoldStrength, cell.TeamID); cellPolygonOptions.InvokeStrokeWidth(0); if (cell.TeamID == GameModel.Player.Team.ID) { MapOverlayClickHandler = new FriendlyOverlayClickHandler(); } else { MapOverlayClickHandler = new EnemyOverlayClickHandler(); } }