Widget:Oarbreaker Isles Map

Use the following code to invoke:





//Define a standard map marker var MapIcon = L.Icon.extend({	options: {		iconSize:    [38, 38],		iconAnchor:   [19, 19],		tooltipAnchor:  [15, 0]	} });

/************************************** //Structure Icons var iconColHomeTown = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconHomeTownHallColonial.png?1529330143518'}); var iconWarHomeTown = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconHomeTownHallWarden.png?1529330143635'}); var iconNeutralTown = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconStaticBase1.png?1529330143698'}); var iconNeutralVPTown = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconVictoryStaticBase2.png?1529349778926', iconSize: [48, 48], tooltipAnchor: [23, 0]}); var iconFort = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconFort.png?1529330143577'}); var iconObservationTower = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconObservationTower.png?1529330144363'});
 * Define all of the icons for the map *

//Resource Icons var iconScrap = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FSalvageMapIcon.png?1529330144427', iconSize: [24, 24], tooltipAnchor: [6, 0]}); var iconComponent = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconComponents.png?1529330143391', iconSize: [24, 24], tooltipAnchor: [6, 0]}); var iconSulfur = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconSulfur.png?1529330144058', iconSize: [24, 24], tooltipAnchor: [6, 0]}); var iconFuel = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconFuel.png?1529330143800', iconSize: [24, 24], tooltipAnchor: [6, 0]});

//Production Icons var iconRefinery = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconManufacturing.png?1529330144485', iconSize: [31, 31]}); var iconWF = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconArmory.png?1529330143459', iconSize: [31, 31]}); var iconSF = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconSupplies.png?1529330143997', iconSize: [31, 31]}); var iconVF = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconVehicle.png?1529330144301', iconSize: [31, 31]}); var iconSS = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconSupplies.png?1529330143997', iconSize: [31, 31]}); var iconMed = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconHospital.png?1529330144575', iconSize: [31, 31]}); var iconWS = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapIconWorkshop.png?1529330144184', iconSize: [31, 31]}); var iconShipyard = new MapIcon({iconUrl: 'https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FShipyard.png?1529330144123', iconSize: [31, 31]});

/*************************************/

// Define overlay layers for the different types of locations var overlayTowns = L.layerGroup; var overlayForts = L.layerGroup; var overlayTowers = L.layerGroup; var overlayProduction = L.layerGroup; var overlayScrap = L.layerGroup; var overlayComponents = L.layerGroup; var overlaySulfur = L.layerGroup; var overlayFuel = L.layerGroup; var overlayRefinery = L.layerGroup; var overlayWF = L.layerGroup; var overlayWS = L.layerGroup; var overlaySS = L.layerGroup; var overlayMed = L.layerGroup; var overlayVF = L.layerGroup; var overlayShipyard = L.layerGroup; var overlayLabel = L.layerGroup;

/************************ /* Format: ["Name", Y, X, "Icon", "Description (Optional)"] TEMPLATE --> ["",, ,"Icon_town",""], Icons are easily interchangable. Scroll down to switchcase statements for list of icons.
 * Standard icon markers *

//Icon marker coordinates var mapData = [

//Scrap nodes ["Camp Posterus", 311.214884, 912.716461, "Icon_scrap", ""], ["Camp Posterus", 319.834724, 813.417667, "Icon_scrap", ""], ["Southeast Infans", 513.381732, 873.472626, "Icon_scrap", ""], ["Pram Road", 535.09828, 722.146021, "Icon_scrap", ""], ["Lion's Head", 554.99415, 583.008788, "Icon_scrap", ""], ["Strong Beach", 659.639734, 723.632529, "Icon_scrap", ""], ["The Satyr Stones", 689.979125, 618.3877, "Icon_scrap", ""], ["The Report", 680.769324, 437.628218, "Icon_scrap", ""], ["Northeast Skelter Course", 830.311026, 541.683841, "Icon_scrap", ""], ["North Palm", 1013.766296, 398.681685, "Icon_scrap", ""], ["South Palm", 924.49411, 356.167531, "Icon_scrap", ""], ["Castor", 592.460455, 1025.393835, "Icon_scrap", ""], ["Damsel", 693.55767, 1022.420817, "Icon_scrap", ""], ["Isle of Psyche", 388.8015, 1306.046714, "Icon_scrap", ""], ["Partisan Island", 683.428655, 1576.888634, "Icon_scrap", ""], ["Grisly Refuge", 952.406309, 1482, "Icon_scrap", ""], ["Kukri", 933.771226, 1179.396156, "Icon_scrap", ""], ["Integrum", 1052.392042, 1746.64795, "Icon_scrap", ""], ["Oblitum", 1204.387709, 1401.5, "Icon_scrap", ""], ["Reliqua", 1426.441213, 1262.5, "Icon_scrap", ""], ["Gold", 1196.006278, 729.578565, "Icon_scrap", ""], ["Silver", 1594.396806, 887.44581, "Icon_scrap", ""],

//Component nodes ["Camp Posterus", 276.968392, 807.681007, "Icon_component", ""], ["The Palm", 1034.877316, 359.437851, "Icon_component", ""], ["Isle of Psyche", 572.822289, 1472.833012, "Icon_component", ""], ["Mount Melodes", 772.385642, 1179, "Icon_component", ""], ["The Conclave", 811.401716, 950.5, "Icon_component", ""], ["Kukri", 958.748535, 1030.447965, "Icon_component", ""], ["Gold", 1088.413198, 706.5, "Icon_component", ""], ["Alabastor Island", 1177.913887, 993.5, "Icon_component", ""], ["Oblitum", 1194.406539, 1513.5, "Icon_component", ""], ["South Fogwood", 1425.770033, 1222.504914, "Icon_component", ""], //Sulfur nodes ["The Palm", 1017.625074, 381.14088, "Icon_sulfur", ""], ["Camp Posterus", 250.775236, 932.932982, "Icon_sulfur", ""], ["Partisan Island", 722.401257, 1595, "Icon_sulfur", ""], ["Grisly Refuge", 913.406079, 1388.5, "Icon_sulfur", ""], ["Integrum", 959.894598, 1732.5, "Icon_sulfur", ""], ["North Oblitum", 1278.906079, 1443, "Icon_sulfur", ""], ["The Emblem", 1414.429732, 1397, "Icon_sulfur", ""], ["Gold", 1137.409983, 820.5, "Icon_sulfur", ""], ["Silver", 1506.413657, 714, "Icon_sulfur", ""], //Fuel nodes ["Camp Posterus", 287.870486, 925, "Icon_fuel", ""], ["The Palisade", 469.652155, 899.337881, "Icon_fuel", ""], ["South Ides", 561.906079, 693.5, "Icon_fuel", ""], ["The Satyr Stones", 707.897353, 598.5, "Icon_fuel", ""], ["Skelter Course", 853.799642, 609.765948, "Icon_fuel", ""], ["The Palm", 924.912739, 336.5, "Icon_fuel", ""], ["Partisan Island", 869.933636, 1595.5, "Icon_fuel", ""], ["Isle of Psyche", 575.805138, 1360.750241, "Icon_fuel", ""], ["Pollux", 590.358179, 1108.935635, "Icon_fuel", ""], ["Integrum", 913.551155, 332.086087, "Icon_fuel", ""], ["Skull Beach", 1111.863457, 1489.18461, "Icon_fuel", ""], ["Kukri", 980.150986, 1155.314712, "Icon_fuel", ""], ["Gold", 1191.839274, 775.363039, "Icon_fuel", ""], ["Silver", 1528.971026, 780.417169, "Icon_fuel", ""], ["Raven's Beak Fort", 1493.887504, 1078.01625, "Icon_fuel", ""], ["Integrum", 1139.507607, 1760.323832, "Icon_fuel", ""], //Towns ["The Palm", 971.825854, 360.032454, "Icon_warHomeTown", ""], ["Camp Posterus", 300.198879, 868.418496, "Icon_colHomeTown", ""], ["The Report", 576.402882, 453.087911, "Icon_NeutralTown", ""], ["Infans", 592.75762, 822.039418, "Icon_NeutralTown", ""], ["Skelter Course", 734.272311, 667.442493, "Icon_NeutralTown", ""], ["The Ides", 649.243183, 657.928836, "Icon_NeutralVPTown", ""], ["The Conclave", 827.340876, 862.47246, "Icon_NeutralVPTown", ""], ["Alabastor Island", 1175.483034, 1069.989102, "Icon_NeutralVPTown", ""], ["Reliqua", 1365.753168, 1353.317697, "Icon_NeutralVPTown", ""], //Forts ["The Palisade", 496.127852, 931.149171, "Icon_fort", ""], ["Strong Beach", 657.280435, 750.38969, "Icon_fort", ""], ["North Skelter Course Beach", 865.11172, 574.387037, "Icon_fort", ""], ["Isle of Psyche", 448.562571, 1306.046714, "Icon_fort", ""], ["Partisan Island", 786.318829, 1576.591333, "Icon_fort", ""], ["East Integrum Beach", 1057.738831, 1837.324993, "Icon_fort", ""], ["North Integrum Beach", 1237.027916, 1742.485725, "Icon_fort", ""], ["Kukri", 974.809249, 1109.530238, "Icon_fort", ""], ["Skull Beach", 1100.868207, 1476.697935, "Icon_fort", ""], ["Raven's Beak Fort", 1474.882107, 1077.188308, "Icon_fort", ""], ["Alabastor Island", 1104.129924, 1031.042569, "Icon_fort", ""], ["Gold", 1130.887221, 734.929997, "Icon_fort", ""], ["Silver", 1546.433636, 871.5, "Icon_fort", ""], //Observation Towers ["Castor", 566.291754, 1050.367184, "Icon_tower", ""], ["Infans", 623.37943, 829.471963, "Icon_tower", ""], ["The Conclave", 782.139127, 814.904176, "Icon_tower", ""], ["Southeast Outstretch", 790.161223, 490.845237, "Icon_tower", ""], ["Gold", 1094.316098, 694.794257, "Icon_tower", ""], ["The Dirk", 1188.270424, 487.277615, "Icon_tower", ""], ["Alabastor Island", 1219.362127, 990.6566, "Icon_tower", ""], ["Crach Woods", 1041.374129, 1318.525579, "Icon_tower", ""], ["Reliqua", 1311.651208, 1436.562195, "Icon_tower", ""], ["Silver", 1497.107986, 702.226801, "Icon_tower", ""], //Refineries ["Camp Posterus", 316.903553, 855, "Icon_Refinery", ""], ["Camp Posterus", 316.853952, 869.5, "Icon_Refinery", ""], ["The Ides", 606.903553, 667.5, "Icon_Refinery", ""], ["The Palm", 982.533906, 381.735484, "Icon_Refinery", ""], ["The Palm", 968.263285, 376.681354, "Icon_Refinery", ""], ["Gold", 1177.262066, 760.200648, "Icon_Refinery", ""], ["Kukri", 972.121927, 1088.12451, "Icon_Refinery", ""], ["Isle of Psyche", 459.879564, 1318.236087, "Icon_Refinery", ""], ["Partisan Island", 806.23559, 1593.240232, "Icon_Refinery", ""], ["Integrum", 1029.802568, 1798.081158, "Icon_Refinery", ""], ["Silver", 1542.659879, 810.741951, "Icon_Refinery", ""], //Weapon Factories ["Camp Posterus", 301.675557, 897.256768, "Icon_WF", ""], ["Camp Posterus", 295.748911, 896.959466, "Icon_WF", ""], ["Skelter Course", 756.87025, 661.793759, "Icon_WF", ""], ["Skelter Course", 766.099304, 654.361215, "Icon_WF", ""], ["The Palm", 943.580683, 346.951176, "Icon_WF", ""], ["The Palm", 944.763336, 340.410537, "Icon_WF", ""], ["Silver", 1529.568633, 836.012602, "Icon_WF", ""], ["Kukri", 973.00127, 1140.152322, "Icon_WF", ""], ["Isle of Psyche", 453.619842, 1337.263401, "Icon_WF", ""], //Workshops ["Camp Posterus", 311.210242, 899.040579, "Icon_WS", ""], ["Camp Posterus", 318.623943, 898.445975, "Icon_WS", ""], ["Skelter Course", 775.309515, 644.847558, "Icon_WS", ""], ["The Palm", 934.361187, 365.086584, "Icon_WS", ""], ["The Palm", 936.147046, 358.248643, "Icon_WS", ""], ["Silver", 1567.319269, 837.796413, "Icon_WS", ""], ["Isle of Psyche", 423.579527, 1329.830856, "Icon_WS", ""], //Supply Stations ["Camp Posterus", 305.260792, 885.364697, "Icon_SS", ""], ["Camp Posterus", 295.731706, 885.364697, "Icon_SS", ""], ["The Palm", 952.493319, 353.491815, "Icon_SS", ""], ["The Palm", 955.179822, 346.05927, "Icon_SS", ""], ["Gold", 1158.534238, 728.092056, "Icon_SS", ""], ["Silver", 1526.891552, 815.796081, "Icon_SS", ""], ["Kukri", 965.281938, 1146.692961, "Icon_SS", ""], ["Partisan Island", 761.631175, 1577.483238, "Icon_SS", ""], ["Isle of Psyche", 406.638787, 1301.587187, "Icon_SS", ""], //Medical Labs/Tents ["Camp Posterus", 324.297118, 880.310567, "Icon_Med", ""], ["Camp Posterus", 325.457651, 885.067395, "Icon_Med", ""], ["Infans", 562.740108, 821.444815, "Icon_Med", ""], ["The Ides", 628.727449, 665.064079, "Icon_Med", ""], ["Skelter Course", 789.275462, 661.793759, "Icon_Med", ""], ["The Palm", 992.640392, 385.303105, "Icon_Med", ""], ["The Palm", 997.693703, 386.492312, "Icon_Med", ""], ["Gold", 1154.37174, 772.984625, "Icon_Med", ""], ["Partisan Island", 781.845784, 1593.537534, "Icon_Med", ""], //Vehicle Factories ["Camp Posterus", 307.346138, 830.66117, "Icon_VF", ""], ["Camp Posterus", 275.813443, 830.958472, "Icon_VF", ""], ["Infans", 570.459031, 775.660341, "Icon_VF", ""], ["The Report", 654.006293, 474.196337, "Icon_VF", ""], ["The Palm", 1018.795302, 352.005306, "Icon_VF", ""], ["The Palm", 1005.712795, 381.14088, "Icon_VF", ""], ["Gold", 1152.871031, 753.065406, "Icon_VF", ""], ["Kukri", 975.684633, 1123.20612, "Icon_VF", ""], ["Partisan Island", 754.473676, 1590.267215, "Icon_VF", ""], //Shipyards ["Camp Posterus", 351.343524, 877.634851, "Icon_Shipyard", ""], ["Camp Posterus", 350.450936, 860.985951, "Icon_Shipyard", ""], ["Camp Posterus", 348.939713, 843.742448, "Icon_Shipyard", ""], ["Oyster Beach", 313.881725, 1083.367682, "Icon_Shipyard", ""], ["South Palisade", 434.583926, 902.310899, "Icon_Shipyard", ""], ["North Palisade", 545.191111, 909.446141, "Icon_Shipyard", ""], ["Pram Road", 479.76929, 756.038423, "Icon_Shipyard", ""], ["The Report", 556.782057, 404.330419, "Icon_Shipyard", ""], ["East Outstretch", 820.794502, 487.574917, "Icon_Shipyard", ""], ["South Outstretch", 752.699014, 420.384715, "Icon_Shipyard", ""], ["Skelter Course", 842.495893, 672.496624, "Icon_Shipyard", ""], ["The Palm", 918.903679, 420.682017, "Icon_Shipyard", ""], ["The Palm", 934.663951, 420.979319, "Icon_Shipyard", ""], ["The Palm", 954.586174, 419.49281, "Icon_Shipyard", ""], ["Gold", 1215.914437, 695.686162, "Icon_Shipyard", ""], ["Silver", 1498.350444, 765.849382, "Icon_Shipyard", ""], ["The Conclave", 818.122063, 1003.096202, "Icon_Shipyard", ""], ["Kukri", 1019.101343, 1113.395161, "Icon_Shipyard", ""], ["Fogwood", 1542.356023, 1320.317199, "Icon_Shipyard", ""], ["North Oblitum", 1285.157215, 1492.752231, "Icon_Shipyard", ""], ["Partisan Island", 762.825707, 1614.348659, "Icon_Shipyard", ""], ["Isle of Psyche", 476.812521, 1353.9123, "Icon_Shipyard", ""],

];

var dir = 'right';

//Adding the markers to the map /* TEMPLATE --> L.marker([, ], {icon: }).addTo.bindTooltip(' ').openTooltip; The mapData entries are in the format [ "Name", Y, X, "Icon", "Description"] for (var i in mapData) { switch(mapData[i][3]) { case "Icon_NeutralTown": L.marker([mapData[i][1],mapData[i][2]], {icon: iconNeutralTown, riseOnHover: true}).addTo(overlayTowns) .bindTooltip(" " + mapData[i][0] + " Town " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_NeutralVPTown": L.marker([mapData[i][1],mapData[i][2]], {icon: iconNeutralVPTown, riseOnHover: true}).addTo(overlayTowns) .bindTooltip(" " + mapData[i][0] + " Victory Condition Town " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_colHomeTown": L.marker([mapData[i][1],mapData[i][2]], {icon: iconColHomeTown, riseOnHover: true}).addTo(overlayTowns) .bindTooltip(" " + mapData[i][0] + " Colonial Port Base " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_warHomeTown": L.marker([mapData[i][1],mapData[i][2]], {icon: iconWarHomeTown, riseOnHover: true}).addTo(overlayTowns) .bindTooltip(" " + mapData[i][0] + " Warden Port Base " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_fort": L.marker([mapData[i][1],mapData[i][2]], {icon: iconFort, riseOnHover: true}).addTo(overlayForts) .bindTooltip(" " + mapData[i][0] + " Fort " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_tower": L.marker([mapData[i][1],mapData[i][2]], {icon: iconObservationTower, riseOnHover: true}).addTo(overlayTowers) .bindTooltip(" " + mapData[i][0] + " Observation Tower " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_Refinery": L.marker([mapData[i][1],mapData[i][2]], {icon: iconRefinery, riseOnHover: true}).addTo(overlayRefinery) .bindTooltip(" " + mapData[i][0] + " Refinery " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_WF": L.marker([mapData[i][1],mapData[i][2]], {icon: iconWF, riseOnHover: true}).addTo(overlayWF) .bindTooltip(" " + mapData[i][0] + " Weapon Factory " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_WS": L.marker([mapData[i][1],mapData[i][2]], {icon: iconWS, riseOnHover: true}).addTo(overlayWS) .bindTooltip(" " + mapData[i][0] + " Workshop " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_SS": L.marker([mapData[i][1],mapData[i][2]], {icon: iconSS, riseOnHover: true}).addTo(overlaySS) .bindTooltip(" " + mapData[i][0] + " Supply Station " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_Med": L.marker([mapData[i][1],mapData[i][2]], {icon: iconMed, riseOnHover: true}).addTo(overlayMed) .bindTooltip(" " + mapData[i][0] + " Medical Lab " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_VF": L.marker([mapData[i][1],mapData[i][2]], {icon: iconVF, riseOnHover: true}).addTo(overlayVF) .bindTooltip(" " + mapData[i][0] + " Vehicle Factory " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_Shipyard": L.marker([mapData[i][1],mapData[i][2]], {icon: iconShipyard, riseOnHover: true}).addTo(overlayShipyard) .bindTooltip(" " + mapData[i][0] + " Shipyard " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_scrap": L.marker([mapData[i][1],mapData[i][2]], {icon: iconScrap, riseOnHover: true}).addTo(overlayScrap) .bindTooltip(" " + mapData[i][0] + " Scrap Node " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_component": L.marker([mapData[i][1],mapData[i][2]], {icon: iconComponent, riseOnHover: true}).addTo(overlayComponents) .bindTooltip(" " + mapData[i][0] + " Component Node " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_sulfur": L.marker([mapData[i][1],mapData[i][2]], {icon: iconSulfur, riseOnHover: true}).addTo(overlaySulfur) .bindTooltip(" " + mapData[i][0] + " Sulfur Node " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; case "Icon_fuel": L.marker([mapData[i][1],mapData[i][2]], {icon: iconFuel, riseOnHover: true}).addTo(overlayFuel) .bindTooltip(" " + mapData[i][0] + " Fuel Node " + mapData[i][4] + "",{                       direction: dir                }).openTooltip; break; } }

/***********************/

/************** //Label coordinates var mapLabels = [ ['The Conclave', 858.913428, 869], ['Camp Posterus', 309.400488, 903.202804], ['Oyster Beach', 350.883805, 1015], ['The Old Pearl' ,237.373471, 1009], ['Doe\'s Head', 356.340029, 618.899762], ['Requiem', 426.960653, 760.170359], ['Pram Road', 537.169448, 745.034224], ['The Ides', 620.896664, 652], ['The Report', 620.903324, 454.5], ['Skelter Course', 792.429043, 621.5], ['The Palisade', 494.901027, 902], ['Infans', 610.912968, 807], ['Strong Beach', 683.397583, 721], ['The Satyr Stones', 716.973099, 575.576244], ['The Palm', 911.907457, 311.5], ['Castor', 583.900798, 1032], ['Pollux', 598.887479, 1095.5], ['Damsel', 700.409754, 1008.5], ['The Outstretch', 856.136548, 398.384384], ['Lion\'s Head', 558.384723, 519], ['Isle of Psyche', 515.905161, 1301.5], ['Eros Lagoon', 449.365451, 1412.183449], ['Partisan Island', 778.901487, 1543], ['Mount Melodes', 783.345128, 1198.126168], ['Kukri', 983.914346, 1095.5], ['Craite\'s Lonliness', 862.91182, 1080.5], ['Grisly Refuge', 947.39919, 1432.5], ['Barrenson', 615.908835, 1198.5], ['Oasis', 968.57557, 712.239264], ['Anchor', 1032.198323, 882.688981], ['Integrum', 1092.915494, 1741], ['The Dirk', 1200.43731, 468.5], ['Gold', 1171.426287, 716.5], ['Alabastor Island', 1195.447184, 1027.5], ['Skull Beach', 1101.403094, 1427.5], ['Crach Woods', 1113.906079, 1343], ['Oblitum', 1222.427665, 1385.5], ['Sandalwood Beach', 1205.870027, 1274], ['Reliqua', 1396.920087, 1292], ['The Emblem', 1436.46854, 1369.5], ['Fogwood', 1527.978874, 1257], ['Raven\'s Beak Fort', 1489.418829, 1053.637504], ['Bronze', 1563.944658, 570], ['Silver', 1571.464636, 785], ];
 * Text Labels *

//Adding the text labels to the map for (var i in mapLabels) { var mapLabel = L.divIcon({               html: ' '+mapLabels[i][0]+' ',                className: 'map-labels',                iconSize: [0, 0]        }); L.marker([mapLabels[i][1], mapLabels[i][2]], {               icon: mapLabel,                zIndexOffset: 605,        }).addTo(overlayLabel) }

/*************/

/*********************** //Initializing map zoom levels and layers var map = L.map('map', {       crs: L.CRS.Simple,        minZoom: -1.25,        maxZoom: 1.75,        zoomDelta: 0.25,        zoomSnap: 0.25,        maxBounds: [                [-600, -1000], //south west                [2448, 3048] //north east        ],         maxBoundsViscosity: 1.0,        layers: [                overlayLabel,                overlayTowns,                overlayForts,                overlayTowers,                overlayScrap,                overlayComponents,                overlaySulfur,                overlayFuel,                overlayRefinery,                overlayWF,                overlayWS,                overlaySS,                overlayMed,                overlayVF,                overlayShipyard        ] }); //Map dimensions var bounds = 0,0], [1848,2048;
 * Initializing the map *

//Map Image (REPLACE WITH WIKI UPLOADED ONE) var image = L.imageOverlay('https://cdn.glitch.com/d95d01cf-e57b-455d-bb60-88c852577d80%2FMapOarbreaker.png?1529330336852', bounds).addTo(map); map.fitBounds(bounds);

//Define the layers var baseMaps = {}; var overlayMaps = { "Labels": overlayLabel, "Towns": overlayTowns, "Forts": overlayForts, "Observation Towers": overlayTowers, "Scrap": overlayScrap, "Components": overlayComponents, "Sulfur": overlaySulfur, "Fuel": overlayFuel, "Refinery": overlayRefinery, "Vehicle Factory": overlayVF, "Shipyard": overlayShipyard, "Supply Station": overlaySS, "Medical Lab": overlayMed, "Weapon Factory": overlayWF, "Workshop": overlayWS };

// Add a control for the layers L.control.layers(baseMaps, overlayMaps, {collapsed:false}).addTo(map);

map.setView([972.266762, 1041.745433], -0.5); /**********************/