// ==UserScript==
// @name WME Mega MapRaid Overlay
// @namespace https://gf.qytechs.cn/users/5252
// @description Creates polygons for MapRaid groups in a WME "Mega MapRaid Groups" layer
// @include https://www.waze.com/editor/*
// @include https://www.waze.com/*/editor/*
// @include https://editor-beta.waze.com/*
// @version 1.5
// @grant none
// @copyright 2014 davielde
// ==/UserScript==
//---------------------------------------------------------------------------------------
//generated by rickzabel's overlay generator
//RZ RaidName will be replaced by the name of the layer in your KML file
//RZ RaidNameNoSpaces will be replaced by the name of the layer in your KML file
//RZ AreaPoints will be replaced by the names, colors, and area points from your KML file
function bootstrap_MapRaidOverlay()
{
var bGreasemonkeyServiceDefined = false;
try {
bGreasemonkeyServiceDefined = (typeof Components.interfaces.gmIGreasemonkeyService === "object");
}
catch (err) { /* Ignore */ }
if (typeof unsafeWindow === "undefined" || ! bGreasemonkeyServiceDefined) {
unsafeWindow = ( function () {
var dummyElem = document.createElement('p');
dummyElem.setAttribute('onclick', 'return window;');
return dummyElem.onclick();
}) ();
}
/* begin running the code! */
setTimeout(InitMapRaidOverlay, 1000);
}
function AddRaidPolygon(raidLayer,groupPoints,groupColor,groupNumber){
var mro_Map = unsafeWindow.Waze.map;
var mro_OL = unsafeWindow.OpenLayers;
var raidGroupLabel = 'Raid Group ' + groupNumber;
var groupName = 'RaidGroup' + groupNumber;
var style = {
strokeColor: groupColor,
strokeOpacity: .8,
strokeWidth: 3,
fillColor: groupColor,
fillOpacity: 0.15,
label: raidGroupLabel,
labelOutlineColor: "black",
labelOutlineWidth: 3,
fontSize: 14,
fontColor: groupColor,
fontOpacity: .85,
fontWeight: "bold"
};
var attributes = {
name: groupName,
number: groupNumber
};
var pnt= [];
for(i=0;i<groupPoints.length;i++){
convPoint = new OpenLayers.Geometry.Point(groupPoints[i].lon,groupPoints[i].lat).transform(new OpenLayers.Projection("EPSG:4326"), mro_Map.getProjectionObject());
//console.log('MapRaid: ' + JSON.stringify(groupPoints[i]) + ', ' + groupPoints[i].lon + ', ' + groupPoints[i].lat);
pnt.push(convPoint);
}
var ring = new mro_OL.Geometry.LinearRing(pnt);
var polygon = new mro_OL.Geometry.Polygon([ring]);
var feature = new mro_OL.Feature.Vector(polygon,attributes,style);
raidLayer.addFeatures([feature]);
}
function CurrentRaidLocation(raid_mapLayer){
var mro_Map = unsafeWindow.Waze.map;
for(i=0;i<raid_mapLayer.features.length;i++){
var raidMapCenter = mro_Map.getCenter();
var raidCenterPoint = new OpenLayers.Geometry.Point(raidMapCenter.lon,raidMapCenter.lat);
var raidCenterCheck = raid_mapLayer.features[i].geometry.components[0].containsPoint(raidCenterPoint);
//console.log('MapRaid: ' + raid_mapLayer.features[i].attributes.number + ': ' + raidCenterCheck);
if(raidCenterCheck === true){
var raidLocationLabel = 'Raid Group ' + raid_mapLayer.features[i].attributes.number + ' - ' + $('.WazeControlLocationInfo').text();
setTimeout(function(){$('.WazeControlLocationInfo').text(raidLocationLabel);},200);
}
}
}
function InitMapRaidOverlay(){
var mro_Map = unsafeWindow.Waze.map;
var mro_OL = unsafeWindow.OpenLayers;
//if (!mro_Map) return;
//if (!mro_OL) return;
var mro_mapLayers = mro_Map.getLayersBy("uniqueName","__MegaMapRaid");
var raid_mapLayer = new mro_OL.Layer.Vector("Mega MapRaid", {
displayInLayerSwitcher: true,
uniqueName: "__MegaMapRaid"
});
I18n.translations.en.layers.name["__MegaMapRaid"] = "Mega MapRaid";
mro_Map.addLayer(raid_mapLayer);
raid_mapLayer.setVisibility(true);
/*
var VBAYAREA = [{lon:'-123.1984913',lat:'38.21390370000001'},{lon:'-122.1135413',lat:'36.705519100000004'},{lon:'-121.0728177',lat:'37.0846502'},{lon:'-121.92964180000001',lat:'38.4254615'},{lon:'-123.1984913',lat:'38.21390370000001'}];
AddRaidPolygon(raid_mapLayer, VBAYAREA,"#000000","BAY AREA");
var VLouisiana = [{lon:'-94.2160034',lat:'33.1030462'},{lon:'-94.1885376',lat:'32.0616279'},{lon:'-93.6199951',lat:'30.7866772'},{lon:'-92.9467423',lat:'30.779895500000002'},{lon:'-92.4126394',lat:'30.7721354'},{lon:'-92.4210739',lat:'31.200341699999996'},{lon:'-92.64315800000001',lat:'31.1975885'},{lon:'-92.6470848',lat:'31.478516400000014'},{lon:'-92.2796631',lat:'31.481231199999996'},{lon:'-92.2745561',lat:'31.3565713'},{lon:'-92.2717373',lat:'31.2041323'},{lon:'-92.4204256',lat:'31.200266099999993'},{lon:'-92.4119637',lat:'30.7696939'},{lon:'-91.4900207',lat:'30.765439200000003'},{lon:'-90.8390807',lat:'32.05348069999999'},{lon:'-90.3592255',lat:'32.3209547'},{lon:'-90.3598993',lat:'33.1064618'},{lon:'-90.8020019',lat:'33.1168498'},{lon:'-94.2160034',lat:'33.1030462'}];
AddRaidPolygon(raid_mapLayer, VLouisiana ,"#000000","Louisiana ");
var VWashingtonDCMetroArea = [{lon:'-76.8332102',lat:'39.0988705'},{lon:'-77.3152422',lat:'39.20429630000001'},{lon:'-77.3014987',lat:'38.665909500000005'},{lon:'-76.7260832',lat:'38.6584103'},{lon:'-76.737078',lat:'39.0594273'},{lon:'-76.8324567',lat:'39.066036'},{lon:'-76.8332102',lat:'39.0988705'}];
AddRaidPolygon(raid_mapLayer, VWashingtonDCMetroArea,"#CDDC39","Washington DC Metro Area");
var VBaltimoreMetroArea = [{lon:'-76.9436055',lat:'39.126339200000004'},{lon:'-76.833552',lat:'39.1020989'},{lon:'-76.8328132',lat:'39.0681976'},{lon:'-76.7374317',lat:'39.0615876'},{lon:'-76.733655',lat:'38.92442719999999'},{lon:'-76.2224262',lat:'38.914276'},{lon:'-76.2356849',lat:'39.24140500000001'},{lon:'-76.1455181',lat:'39.6276665'},{lon:'-76.9434336',lat:'39.62978350000001'},{lon:'-76.9436055',lat:'39.126339200000004'}];
AddRaidPolygon(raid_mapLayer, VBaltimoreMetroArea,"#F4EB37","Baltimore Metro Area");
var VLouisiana = [{lon:'-93.8995356',lat:'33.01674289999999'},{lon:'-93.903835',lat:'32.03163589999999'},{lon:'-93.9038354',lat:'31.911386900000004'},{lon:'-93.7363123',lat:'31.546035500000002'},{lon:'-93.581676',lat:'31.1939471'},{lon:'-93.4055604',lat:'31.0137268'},{lon:'-93.0919899',lat:'30.836854400000004'},{lon:'-91.4897677',lat:'30.8552952'},{lon:'-91.32224420000001',lat:'31.223338600000005'},{lon:'-91.1719028',lat:'31.597272'},{lon:'-90.9914931',lat:'31.787329500000013'},{lon:'-90.8454481',lat:'32.155365'},{lon:'-90.8540429',lat:'32.886983'},{lon:'-91.0301579',lat:'33.07435340000001'},{lon:'-93.8995356',lat:'33.01674289999999'}];
AddRaidPolygon(raid_mapLayer, VLouisiana,"#FF0000","Louisiana");
var VWashingtonDCMetroArea = [{lon:'-77.1963936',lat:'39.105456100000005'},{lon:'-77.2017631',lat:'38.766325099999996'},{lon:'-76.81946860000001',lat:'38.724448300000006'},{lon:'-76.8183961',lat:'39.0637783'},{lon:'-77.1963936',lat:'39.105456100000005'}];
AddRaidPolygon(raid_mapLayer, VWashingtonDCMetroArea,"#FF0000","Washington DC Metro Area");
var VBaltimoreMetroArea = [{lon:'-76.829275',lat:'39.561706'},{lon:'-76.832133',lat:'39.06526'},{lon:'-76.269069',lat:'38.999764'},{lon:'-76.269069',lat:'39.49557'},{lon:'-76.829275',lat:'39.561706'}];
AddRaidPolygon(raid_mapLayer, VBaltimoreMetroArea,"#FF0000","Baltimore Metro Area");
var VBayArea = [{lon:'-122.908388',lat:'38.084948000000004'},{lon:'-122.555345',lat:'37.274669'},{lon:'-122.378823',lat:'37.31679700000001'},{lon:'-122.371763',lat:'36.866218999999994'},{lon:'-122.00106800000002',lat:'36.818188'},{lon:'-121.44326',lat:'36.98193500000001'},{lon:'-121.446791',lat:'37.305565'},{lon:'-121.619782',lat:'37.24376'},{lon:'-121.62331200000001',lat:'37.395372'},{lon:'-121.626842',lat:'37.549477'},{lon:'-121.62331200000001',lat:'37.85952'},{lon:'-121.803364',lat:'37.800963'},{lon:'-121.81395500000002',lat:'38.109953'},{lon:'-122.170528',lat:'38.001537'},{lon:'-122.177589',lat:'38.154385'},{lon:'-122.35411000000002',lat:'38.096062999999994'},{lon:'-122.35411000000002',lat:'38.251486'},{lon:'-122.908388',lat:'38.084948000000004'}];
AddRaidPolygon(raid_mapLayer, VBayArea,"#FF0000","Bay Area");
*/
var V01Bay = [{lon:'-122.5270723',lat:'37.8003666'},{lon:'-122.5214949',lat:'37.7631096'},{lon:'-122.36382450000002',lat:'37.7726245'},{lon:'-122.4198814',lat:'37.832891800000006'},{lon:'-122.5270723',lat:'37.8003666'}];
AddRaidPolygon(raid_mapLayer, V01Bay,"#B7DBAB","01 Bay");
var V02Bay = [{lon:'-122.5214949',lat:'37.7631096'},{lon:'-122.57380879999998',lat:'37.7000821'},{lon:'-122.3417501',lat:'37.7061253'},{lon:'-122.36382450000002',lat:'37.7726245'},{lon:'-122.5214949',lat:'37.7631096'}];
AddRaidPolygon(raid_mapLayer, V02Bay,"#795046","02 Bay");
var V04Bay = [{lon:'-122.51456080000001',lat:'37.47610650000001'},{lon:'-122.4438835',lat:'37.3767527'},{lon:'-122.11879549999999',lat:'37.4878954'},{lon:'-122.2285543',lat:'37.6423178'},{lon:'-122.51456080000001',lat:'37.47610650000001'}];
AddRaidPolygon(raid_mapLayer, V04Bay,"#7CCFA9","04 Bay");
var V05Bay = [{lon:'-122.4438835',lat:'37.3767527'},{lon:'-122.4294368',lat:'37.1932799'},{lon:'-122.03259220000001',lat:'37.4443603'},{lon:'-122.11879549999999',lat:'37.4878954'},{lon:'-122.4438835',lat:'37.3767527'}];
AddRaidPolygon(raid_mapLayer, V05Bay,"#3F5BA9","05 Bay");
var V06Bay = [{lon:'-122.4294368',lat:'37.1932799'},{lon:'-122.3565912',lat:'37.0827295'},{lon:'-121.93353970000001',lat:'37.3909689'},{lon:'-122.03259220000001',lat:'37.4443603'},{lon:'-122.4294368',lat:'37.1932799'}];
AddRaidPolygon(raid_mapLayer, V06Bay,"#F8971B","06 Bay");
var V07Bay = [{lon:'-122.3565912',lat:'37.0827295'},{lon:'-122.1717388',lat:'36.9635998'},{lon:'-121.86010870000001',lat:'37.2997129'},{lon:'-121.93353970000001',lat:'37.3909689'},{lon:'-122.3565912',lat:'37.0827295'}];
AddRaidPolygon(raid_mapLayer, V07Bay,"#93D7E8","07 Bay");
var V08Bay = [{lon:'-122.1717388',lat:'36.9635998'},{lon:'-121.9497087',lat:'36.7649961'},{lon:'-121.7499174',lat:'37.2364532'},{lon:'-121.86010870000001',lat:'37.2997129'},{lon:'-122.1717388',lat:'36.9635998'}];
AddRaidPolygon(raid_mapLayer, V08Bay,"#D698AD","08 Bay");
var V09Bay = [{lon:'-121.9497087',lat:'36.7649961'},{lon:'-121.36778200000002',lat:'36.9753113'},{lon:'-121.7499225',lat:'37.237550799999994'},{lon:'-121.9497087',lat:'36.7649961'}];
AddRaidPolygon(raid_mapLayer, V09Bay,"#F4B400","09 Bay");
var V10Bay = [{lon:'-121.3738973',lat:'37.5234303'},{lon:'-121.86010870000001',lat:'37.2997129'},{lon:'-121.36778200000002',lat:'36.9753113'},{lon:'-121.0728177',lat:'37.0846502'},{lon:'-121.3738973',lat:'37.5234303'}];
AddRaidPolygon(raid_mapLayer, V10Bay,"#F4EB37","10 Bay");
var V03Bay = [{lon:'-122.57380879999998',lat:'37.7000821'},{lon:'-122.51456080000001',lat:'37.47610650000001'},{lon:'-122.2285543',lat:'37.6423178'},{lon:'-122.3417501',lat:'37.7061253'},{lon:'-122.57380879999998',lat:'37.7000821'}];
AddRaidPolygon(raid_mapLayer, V03Bay,"#FFDD5E","03 Bay");
var V11Bay = [{lon:'-121.93353970000001',lat:'37.3909689'},{lon:'-121.86010870000001',lat:'37.2997129'},{lon:'-121.3738973',lat:'37.5234303'},{lon:'-121.46141780000002',lat:'37.6643656'},{lon:'-121.93353970000001',lat:'37.3909689'}];
AddRaidPolygon(raid_mapLayer, V11Bay,"#A7B5D7","11 Bay");
var V12Bay = [{lon:'-122.11879549999999',lat:'37.4878954'},{lon:'-121.93353970000001',lat:'37.3909689'},{lon:'-121.46141780000002',lat:'37.6643656'},{lon:'-121.51864160000001',lat:'37.7581309'},{lon:'-122.11879549999999',lat:'37.4878954'}];
AddRaidPolygon(raid_mapLayer, V12Bay,"#E6EEA3","12 Bay");
var V13Bay = [{lon:'-122.2285543',lat:'37.6423178'},{lon:'-122.11879549999999',lat:'37.4878954'},{lon:'-121.51864160000001',lat:'37.7581309'},{lon:'-121.57474559999999',lat:'37.8440374'},{lon:'-122.2285543',lat:'37.6423178'}];
AddRaidPolygon(raid_mapLayer, V13Bay,"#62AF44","13 Bay");
var V14Bay = [{lon:'-121.63575640000002',lat:'37.9473045'},{lon:'-122.36382450000002',lat:'37.7726245'},{lon:'-122.2285543',lat:'37.6423178'},{lon:'-121.57474559999999',lat:'37.8440374'},{lon:'-121.63575640000002',lat:'37.9473045'}];
AddRaidPolygon(raid_mapLayer, V14Bay,"#009D57","14 Bay");
var V17Bay = [{lon:'-121.92965130000002',lat:'38.4253972'},{lon:'-122.24977779999999',lat:'38.37277300000001'},{lon:'-122.17400570000001',lat:'38.00995820000001'},{lon:'-121.7443213',lat:'38.10823870000001'},{lon:'-121.92965130000002',lat:'38.4253972'}];
AddRaidPolygon(raid_mapLayer, V17Bay,"#7C3592","17 Bay");
var V15Bay = [{lon:'-122.4520135',lat:'37.9473165'},{lon:'-122.36382450000002',lat:'37.7726245'},{lon:'-121.9977359',lat:'37.85563849999999'},{lon:'-122.27966590000001',lat:'37.992761099999996'},{lon:'-122.4520135',lat:'37.9473165'}];
AddRaidPolygon(raid_mapLayer, V15Bay,"#A61B4A","15 Bay");
var V16Bay = [{lon:'-122.27966590000001',lat:'37.992761099999996'},{lon:'-121.9977359',lat:'37.85563849999999'},{lon:'-121.63575640000002',lat:'37.9473045'},{lon:'-121.7443213',lat:'38.10823870000001'},{lon:'-122.27966590000001',lat:'37.992761099999996'}];
AddRaidPolygon(raid_mapLayer, V16Bay,"#9FC3FF","16 Bay");
var V18Bay = [{lon:'-122.85604470000001',lat:'38.27198909999999'},{lon:'-122.4520135',lat:'37.9473165'},{lon:'-122.17400570000001',lat:'38.00995820000001'},{lon:'-122.24977779999999',lat:'38.37277300000001'},{lon:'-122.85604470000001',lat:'38.27198909999999'}];
AddRaidPolygon(raid_mapLayer, V18Bay,"#DB4436","18 Bay");
var V19Bay = [{lon:'-123.18989000000002',lat:'38.2132375'},{lon:'-123.0327093',lat:'37.99328249999999'},{lon:'-122.4520135',lat:'37.9473165'},{lon:'-122.85604470000001',lat:'38.27198909999999'},{lon:'-123.18989000000002',lat:'38.2132375'}];
AddRaidPolygon(raid_mapLayer, V19Bay,"#EE9C96","19 Bay");
var V20Bay = [{lon:'-123.0327093',lat:'37.99328249999999'},{lon:'-122.5270723',lat:'37.8003666'},{lon:'-122.4198814',lat:'37.832891800000006'},{lon:'-122.4520135',lat:'37.9473165'},{lon:'-123.0327093',lat:'37.99328249999999'}];
AddRaidPolygon(raid_mapLayer, V20Bay,"#FAD199","20 Bay");
var VLA1 = [{lon:'-93.5980225',lat:'32.5329207'},{lon:'-93.6254883',lat:'33.0800354'},{lon:'-94.1940308',lat:'33.0823367'},{lon:'-94.1912842',lat:'32.4819631'},{lon:'-94.0841675',lat:'32.4541559'},{lon:'-93.9276123',lat:'32.4286585'},{lon:'-93.8287354',lat:'32.44720280000001'},{lon:'-93.7353516',lat:'32.484280000000005'},{lon:'-93.5980225',lat:'32.5329207'}];
AddRaidPolygon(raid_mapLayer, VLA1,"#DB4436","LA 1");
var VLA2 = [{lon:'-93.6021423',lat:'32.6023617'},{lon:'-93.5980225',lat:'32.5329207'},{lon:'-93.5513306',lat:'32.5282894'},{lon:'-93.4689331',lat:'32.5537586'},{lon:'-93.3096313',lat:'32.5769062'},{lon:'-93.2272339',lat:'32.5676479'},{lon:'-93.1887817',lat:'32.5537586'},{lon:'-93.114624',lat:'32.5514435'},{lon:'-93.0267334',lat:'32.5514435'},{lon:'-92.9278564',lat:'32.5537586'},{lon:'-92.8125',lat:'32.5352362'},{lon:'-92.7328491',lat:'32.5352362'},{lon:'-92.6669312',lat:'32.5259736'},{lon:'-92.5213623',lat:'32.519026'},{lon:'-92.37854',lat:'32.505129200000006'},{lon:'-92.326355',lat:'32.49817999999999'},{lon:'-92.34558110000002',lat:'33.0892404'},{lon:'-93.6254883',lat:'33.0800354'},{lon:'-93.6021423',lat:'32.6023617'}];
AddRaidPolygon(raid_mapLayer, VLA2,"#4186F0","LA 2");
var VLA3 = [{lon:'-92.34558110000002',lat:'33.0892404'},{lon:'-92.3291016',lat:'32.51671'},{lon:'-92.142334',lat:'32.52134199999999'},{lon:'-92.0187378',lat:'32.5097617'},{lon:'-91.7770613',lat:'32.4715803'},{lon:'-91.6836639',lat:'32.4611522'},{lon:'-91.683677',lat:'33.07547720000001'},{lon:'-92.34558110000002',lat:'33.0892404'}];
AddRaidPolygon(raid_mapLayer, VLA3,"#F8971B","LA 3");
var VLA4 = [{lon:'-91.6864146',lat:'33.0731485'},{lon:'-91.6754274',lat:'31.7468377'},{lon:'-91.3238561',lat:'31.721141499999995'},{lon:'-91.21399',lat:'31.7421663'},{lon:'-91.2112434',lat:'31.8075461'},{lon:'-91.1480704',lat:'31.89153789999999'},{lon:'-91.0244711',lat:'32.0173821'},{lon:'-90.9530581',lat:'32.147704899999994'},{lon:'-90.8596719',lat:'32.294095500000005'},{lon:'-90.84593860000001',lat:'32.4077919'},{lon:'-90.9310848',lat:'32.4819655'},{lon:'-90.96679130000001',lat:'32.6625074'},{lon:'-91.04644420000001',lat:'32.8172977'},{lon:'-91.0546841',lat:'33.0593378'},{lon:'-91.6864146',lat:'33.0731485'}];
AddRaidPolygon(raid_mapLayer, VLA4,"#009D57","LA 4");
var VLA5 = [{lon:'-92.3291016',lat:'32.51671'},{lon:'-92.2988892',lat:'31.77721250000001'},{lon:'-91.6809082',lat:'31.742182800000002'},{lon:'-91.6795349',lat:'32.4564735'},{lon:'-92.0187378',lat:'32.5097617'},{lon:'-92.142334',lat:'32.52134199999999'},{lon:'-92.26593020000001',lat:'32.51671000000001'},{lon:'-92.3291016',lat:'32.51671'}];
AddRaidPolygon(raid_mapLayer, VLA5,"#7C3592","LA 5");
var VLA6 = [{lon:'-93.5980225',lat:'32.5329207'},{lon:'-93.5678101',lat:'32.1151486'},{lon:'-93.4332275',lat:'31.970803900000003'},{lon:'-93.2437134',lat:'31.8378994'},{lon:'-93.114624',lat:'31.81573'},{lon:'-92.9374695',lat:'31.820397599999996'},{lon:'-92.8455205',lat:'31.8560091'},{lon:'-92.7218628',lat:'31.90554150000001'},{lon:'-92.6147461',lat:'31.90554150000001'},{lon:'-92.4911499',lat:'31.87989'},{lon:'-92.4005127',lat:'31.83731600000001'},{lon:'-92.3036956',lat:'31.7848006'},{lon:'-92.3291016',lat:'32.51671'},{lon:'-92.8125',lat:'32.5352362'},{lon:'-92.9278564',lat:'32.5537586'},{lon:'-93.1887817',lat:'32.5537586'},{lon:'-93.2272339',lat:'32.5676479'},{lon:'-93.3206177',lat:'32.575749'},{lon:'-93.4689331',lat:'32.5537586'},{lon:'-93.5513306',lat:'32.5282894'},{lon:'-93.5980225',lat:'32.5329207'}];
AddRaidPolygon(raid_mapLayer, VLA6,"#F4EB37","LA 6");
var VLA7 = [{lon:'-94.1912842',lat:'32.4819631'},{lon:'-94.1638184',lat:'32.0686107'},{lon:'-93.9358521',lat:'31.637014000000004'},{lon:'-93.4140015',lat:'31.954492700000003'},{lon:'-93.5678101',lat:'32.1151486'},{lon:'-93.5980225',lat:'32.5329207'},{lon:'-93.8287354',lat:'32.44720280000001'},{lon:'-93.9276123',lat:'32.4286585'},{lon:'-94.0841675',lat:'32.4541559'},{lon:'-94.1912842',lat:'32.4819631'}];
AddRaidPolygon(raid_mapLayer, VLA7,"#93D7E8","LA 7");
var VLA8 = [{lon:'-93.9358521',lat:'31.637014000000004'},{lon:'-93.7435913',lat:'31.2527262'},{lon:'-92.6531982',lat:'31.3231404'},{lon:'-92.6559448',lat:'31.494261799999993'},{lon:'-92.1713408',lat:'31.4839415'},{lon:'-92.179576',lat:'31.770354'},{lon:'-92.2988892',lat:'31.77721250000001'},{lon:'-92.3675537',lat:'31.8192307'},{lon:'-92.4856567',lat:'31.8775576'},{lon:'-92.6147461',lat:'31.90554150000001'},{lon:'-92.7218628',lat:'31.90554150000001'},{lon:'-92.9278564',lat:'31.8192307'},{lon:'-93.1256104',lat:'31.814563000000003'},{lon:'-93.2437134',lat:'31.8378994'},{lon:'-93.4140015',lat:'31.954492700000003'},{lon:'-93.9358521',lat:'31.637014000000004'}];
AddRaidPolygon(raid_mapLayer, VLA8,"#777777","LA 8");
var VLA9 = [{lon:'-93.7435913',lat:'31.2527262'},{lon:'-93.60345510000002',lat:'30.800877100000005'},{lon:'-93.5979633',lat:'30.777288200000005'},{lon:'-92.2509741',lat:'30.764665800000003'},{lon:'-92.24030270000002',lat:'31.179761299999996'},{lon:'-92.6350977',lat:'31.1740449'},{lon:'-92.6531982',lat:'31.3231404'},{lon:'-93.7435913',lat:'31.2527262'}];
AddRaidPolygon(raid_mapLayer, VLA9,"#EE9C96","LA 9");
var VLA10 = [{lon:'-92.179576',lat:'31.770354'},{lon:'-92.1713408',lat:'31.4839415'},{lon:'-92.2372417',lat:'31.4815999'},{lon:'-92.24030270000002',lat:'31.179761299999996'},{lon:'-92.2509741',lat:'30.764665800000003'},{lon:'-91.4683964',lat:'30.757586899999996'},{lon:'-91.3475787',lat:'31.0026769'},{lon:'-91.5233149',lat:'31.00503'},{lon:'-91.4903651',lat:'31.21426569999999'},{lon:'-91.4409397',lat:'31.2917303'},{lon:'-91.4162271',lat:'31.3761642'},{lon:'-91.4711449',lat:'31.479258099999992'},{lon:'-91.3805315',lat:'31.509696299999998'},{lon:'-91.3503273',lat:'31.579899599999997'},{lon:'-91.3228693',lat:'31.713140300000003'},{lon:'-92.179576',lat:'31.770354'}];
AddRaidPolygon(raid_mapLayer, VLA10,"#F4B400","LA 10");
var VB1 = [{lon:'-76.549725',lat:'39.197233'},{lon:'-76.529858',lat:'39.209623'},{lon:'-76.529388',lat:'39.30269'},{lon:'-76.661997',lat:'39.302026'},{lon:'-76.661637',lat:'39.256042'},{lon:'-76.549725',lat:'39.197233'}];
AddRaidPolygon(raid_mapLayer, VB1,"#F4EB37","B1");
var VB2 = [{lon:'-76.529674',lat:'39.371972'},{lon:'-76.595736',lat:'39.37226'},{lon:'-76.59599300000002',lat:'39.301993'},{lon:'-76.529388',lat:'39.30215900000001'},{lon:'-76.529674',lat:'39.371972'}];
AddRaidPolygon(raid_mapLayer, VB2,"#009D57","B2");
var VB3 = [{lon:'-76.594877',lat:'39.37226'},{lon:'-76.662426',lat:'39.372128'},{lon:'-76.661911',lat:'39.301495'},{lon:'-76.59522100000001',lat:'39.30205900000001'},{lon:'-76.594877',lat:'39.37226'}];
AddRaidPolygon(raid_mapLayer, VB3,"#3F5BA9","B3");
var VB4 = [{lon:'-76.662083',lat:'39.372161000000006'},{lon:'-76.711294',lat:'39.371957'},{lon:'-76.711161',lat:'39.27783800000001'},{lon:'-76.660864',lat:'39.25584299999999'},{lon:'-76.662083',lat:'39.372161000000006'}];
AddRaidPolygon(raid_mapLayer, VB4,"#DB4436","B4");
var VB5 = [{lon:'-76.663971',lat:'39.421873'},{lon:'-76.662426',lat:'39.372128'},{lon:'-76.529674',lat:'39.371972'},{lon:'-76.529858',lat:'39.209623'},{lon:'-76.426329',lat:'39.17987'},{lon:'-76.356168',lat:'39.29889500000001'},{lon:'-76.42148700000001',lat:'39.426094'},{lon:'-76.663971',lat:'39.421873'}];
AddRaidPolygon(raid_mapLayer, VB5,"#7C3592","B5");
var VB6 = [{lon:'-76.666031',lat:'39.471185'},{lon:'-76.882861',lat:'39.471144'},{lon:'-76.880921',lat:'39.360775000000004'},{lon:'-76.713341',lat:'39.195119'},{lon:'-76.641271',lat:'39.247346'},{lon:'-76.711161',lat:'39.27783800000001'},{lon:'-76.711294',lat:'39.371957'},{lon:'-76.662426',lat:'39.372128'},{lon:'-76.666031',lat:'39.471185'}];
AddRaidPolygon(raid_mapLayer, VB6,"#F8971B","B6");
var VB7 = [{lon:'-76.223175',lat:'39.296592000000004'},{lon:'-76.14404300000001',lat:'39.612053'},{lon:'-76.512811',lat:'39.613600000000005'},{lon:'-76.356168',lat:'39.29889500000001'},{lon:'-76.223175',lat:'39.296592000000004'}];
AddRaidPolygon(raid_mapLayer, VB7,"#795046","B7");
var VB8 = [{lon:'-76.46827700000001',lat:'39.192884'},{lon:'-76.529858',lat:'39.209623'},{lon:'-76.549725',lat:'39.197233'},{lon:'-76.641271',lat:'39.247346'},{lon:'-76.8332159',lat:'39.0995999'},{lon:'-76.830351',lat:'39.067857'},{lon:'-76.739502',lat:'39.047985999999995'},{lon:'-76.735569',lat:'38.934844000000005'},{lon:'-76.297302',lat:'38.933241'},{lon:'-76.46827700000001',lat:'39.192884'}];
AddRaidPolygon(raid_mapLayer, VB8,"#0BA9CC","B8");
var VB9 = [{lon:'-76.830826',lat:'39.60833300000001'},{lon:'-76.960602',lat:'39.608333'},{lon:'-76.9543093',lat:'39.1257251'},{lon:'-76.8332159',lat:'39.0995999'},{lon:'-76.713339',lat:'39.193106'},{lon:'-76.880921',lat:'39.360775000000004'},{lon:'-76.882861',lat:'39.471144'},{lon:'-76.830826',lat:'39.60833300000001'}];
AddRaidPolygon(raid_mapLayer, VB9,"#A61B4A","B9");
var VB10 = [{lon:'-76.830826',lat:'39.60833300000001'},{lon:'-76.884633',lat:'39.470042'},{lon:'-76.666031',lat:'39.471185'},{lon:'-76.663971',lat:'39.421873'},{lon:'-76.414719',lat:'39.425586'},{lon:'-76.512811',lat:'39.613600000000005'},{lon:'-76.830826',lat:'39.60833300000001'}];
AddRaidPolygon(raid_mapLayer, VB10,"#000000","B10");
var V01Washington = [{lon:'-77.0780694',lat:'38.81138159999999'},{lon:'-77.202301',lat:'38.664067'},{lon:'-76.9111633',lat:'38.66192240000001'},{lon:'-76.9805835',lat:'38.8124495'},{lon:'-77.0780694',lat:'38.81138159999999'}];
AddRaidPolygon(raid_mapLayer, V01Washington,"#FF0000","01 Washington");
var V02Washington = [{lon:'-76.9805835',lat:'38.8124495'},{lon:'-76.9111633',lat:'38.66192240000001'},{lon:'-76.7260877',lat:'38.6591397'},{lon:'-76.7312622',lat:'38.8274054'},{lon:'-76.9071276',lat:'38.8402637'},{lon:'-76.9805835',lat:'38.8124495'}];
AddRaidPolygon(raid_mapLayer, V02Washington,"#FF8800","02 Washington");
var V03Washington = [{lon:'-76.9071276',lat:'38.8402637'},{lon:'-76.7312622',lat:'38.8274054'},{lon:'-76.7346954',lat:'38.93965060000001'},{lon:'-76.8782043',lat:'38.9364461'},{lon:'-76.8700501',lat:'38.89851440000001'},{lon:'-76.9071276',lat:'38.8402637'}];
AddRaidPolygon(raid_mapLayer, V03Washington,"#EEFF00","03 Washington");
var V04Washington = [{lon:'-76.7346954',lat:'38.93965060000001'},{lon:'-76.739502',lat:'39.047985999999995'},{lon:'-76.830351',lat:'39.067857'},{lon:'-76.8332159',lat:'39.0995999'},{lon:'-76.9173431',lat:'38.9823641'},{lon:'-76.8858428',lat:'38.9620686'},{lon:'-76.8782043',lat:'38.9364461'},{lon:'-76.7346954',lat:'38.93965060000001'}];
AddRaidPolygon(raid_mapLayer, V04Washington,"#66FF00","04 Washington");
var V05Washington = [{lon:'-76.9173431',lat:'38.9823641'},{lon:'-76.8332159',lat:'39.0995999'},{lon:'-77.1147524',lat:'39.1603172'},{lon:'-77.0643436',lat:'39.0047607'},{lon:'-76.9517512',lat:'39.00636120000001'},{lon:'-76.9173431',lat:'38.9823641'}];
AddRaidPolygon(raid_mapLayer, V05Washington,"#00FF22","05 Washington");
var V06Washington = [{lon:'-77.0643436',lat:'39.0047607'},{lon:'-77.1147524',lat:'39.1603172'},{lon:'-77.3152529',lat:'39.2050256'},{lon:'-77.31216430000002',lat:'39.142842400000006'},{lon:'-77.1453593',lat:'38.97488129999999'},{lon:'-77.0643436',lat:'39.0047607'}];
AddRaidPolygon(raid_mapLayer, V06Washington,"#00FFAA","06 Washington");
var V07Washington = [{lon:'-77.0643436',lat:'39.0047607'},{lon:'-77.1453593',lat:'38.97488129999999'},{lon:'-77.1728259',lat:'38.9161489'},{lon:'-77.1508461',lat:'38.8573705'},{lon:'-77.0780694',lat:'38.81138159999999'},{lon:'-76.9805835',lat:'38.8124495'},{lon:'-76.9071276',lat:'38.8402637'},{lon:'-76.8700501',lat:'38.89851440000001'},{lon:'-76.8858428',lat:'38.9620686'},{lon:'-76.9517512',lat:'39.00636120000001'},{lon:'-77.0643436',lat:'39.0047607'}];
AddRaidPolygon(raid_mapLayer, V07Washington,"#00CCFF","07 Washington");
var V08Washington = [{lon:'-77.1453593',lat:'38.97488129999999'},{lon:'-77.31216430000002',lat:'39.142842400000006'},{lon:'-77.31216430000002',lat:'39.0010431'},{lon:'-77.169342',lat:'38.9273658'},{lon:'-77.1453593',lat:'38.97488129999999'}];
AddRaidPolygon(raid_mapLayer, V08Washington,"#0044FF","08 Washington");
var V09Washington = [{lon:'-77.3052979',lat:'38.7985138'},{lon:'-77.301509',lat:'38.6666389'},{lon:'-77.202301',lat:'38.664067'},{lon:'-77.0780694',lat:'38.81138159999999'},{lon:'-77.1236929',lat:'38.8408453'},{lon:'-77.3052979',lat:'38.7985138'}];
AddRaidPolygon(raid_mapLayer, V09Washington,"#4400FF","09 Washington");
var V10Washington = [{lon:'-77.169342',lat:'38.9273658'},{lon:'-77.31216430000002',lat:'39.0010431'},{lon:'-77.3052979',lat:'38.7985138'},{lon:'-77.1236929',lat:'38.8408453'},{lon:'-77.1508461',lat:'38.8573705'},{lon:'-77.1728259',lat:'38.9161489'},{lon:'-77.169342',lat:'38.9273658'}];
AddRaidPolygon(raid_mapLayer, V10Washington,"#CC00FF","10 Washington");
var VSouthernSwamps = [{lon:'-75.2316284',lat:'39.728841499999994'},{lon:'-75.4080963',lat:'39.6088623'},{lon:'-75.5097198',lat:'39.6046301'},{lon:'-75.5330658',lat:'39.5490593'},{lon:'-75.5461121',lat:'39.4780756'},{lon:'-75.526886',lat:'39.45263090000001'},{lon:'-75.298233',lat:'39.291797'},{lon:'-75.13800680000001',lat:'39.17812179999999'},{lon:'-74.9460127',lat:'39.1822935'},{lon:'-74.8237609',lat:'39.3226124'},{lon:'-74.8937988',lat:'39.45263090000001'},{lon:'-75.0743866',lat:'39.5839947'},{lon:'-75.2316284',lat:'39.728841499999994'}];
AddRaidPolygon(raid_mapLayer, VSouthernSwamps,"#000000","Southern Swamps");
var VPineBarrens = [{lon:'-74.6287377',lat:'39.9660659'},{lon:'-74.867002',lat:'39.7536552'},{lon:'-74.7804853',lat:'39.65011100000001'},{lon:'-74.7104481',lat:'39.5882275'},{lon:'-74.6088254',lat:'39.58664'},{lon:'-74.48729',lat:'39.546411500000005'},{lon:'-74.4577644',lat:'39.6003969'},{lon:'-74.3149433',lat:'39.6992609'},{lon:'-74.3829205',lat:'39.9671184'},{lon:'-74.6287377',lat:'39.9660659'}];
AddRaidPolygon(raid_mapLayer, VPineBarrens,"#000000","Pine Barrens");
var VThePiedmont = [{lon:'-75.168457',lat:'40.6337567'},{lon:'-75.1677704',lat:'40.57432639999999'},{lon:'-75.1121521',lat:'40.58423510000001'},{lon:'-75.06271360000001',lat:'40.5560696'},{lon:'-75.04280090000002',lat:'40.4270875'},{lon:'-74.9473572',lat:'40.4030392'},{lon:'-74.8738861',lat:'40.3418341'},{lon:'-74.7633362',lat:'40.41611'},{lon:'-74.8086548',lat:'40.473591400000004'},{lon:'-74.8951721',lat:'40.4897818'},{lon:'-74.9398041',lat:'40.6040481'},{lon:'-75.0682068',lat:'40.6478245'},{lon:'-75.168457',lat:'40.6337567'}];
AddRaidPolygon(raid_mapLayer, VThePiedmont,"#000000","The Piedmont");
var VCrystalLake = [{lon:'-74.8611829',lat:'41.201130600000006'},{lon:'-74.9682992',lat:'41.07753929999999'},{lon:'-75.1111209',lat:'40.97341819999999'},{lon:'-75.0664891',lat:'40.938674600000006'},{lon:'-74.7815323',lat:'40.9490477'},{lon:'-74.8117446',lat:'41.06149150000001'},{lon:'-74.7760391',lat:'41.1070362'},{lon:'-74.8611829',lat:'41.201130600000006'}];
AddRaidPolygon(raid_mapLayer, VCrystalLake,"#000000","Crystal Lake");
var VTheHighlands = [{lon:'-74.4179535',lat:'41.2261833'},{lon:'-74.5079041',lat:'41.1827883'},{lon:'-74.5024109',lat:'41.0953946'},{lon:'-74.3582153',lat:'41.0213551'},{lon:'-74.2971039',lat:'41.041556'},{lon:'-74.2483521',lat:'41.0493239'},{lon:'-74.1755676',lat:'41.1171246'},{lon:'-74.4179535',lat:'41.2261833'}];
AddRaidPolygon(raid_mapLayer, VTheHighlands,"#000000","The Highlands");
setTimeout(function(){CurrentRaidLocation(raid_mapLayer);},3000);
mro_Map.events.register("moveend", Waze.map, function(){CurrentRaidLocation(raid_mapLayer);});
mro_Map.events.register("zoomend", Waze.map, function(){CurrentRaidLocation(raid_mapLayer);});
}
bootstrap_MapRaidOverlay();