The Wiki for Tale 6 is in read-only mode and is available for archival and reference purposes only. Please visit the current Tale 11 Wiki in the meantime.

If you have any issues with this Wiki, please post in #wiki-editing on Discord or contact Brad in-game.

Difference between revisions of "User:Sneferu/Marble and dowsing"

From ATITD6
Jump to navigationJump to search
Line 17: Line 17:
  
  
<googlemap zoom="8" height="1074" lat=2000 lon=1500 controls="small" showposition="yes" showregion="yes" scrollwheel="nothing" googlemap.Circle(2000, 1600)>
+
<googlemap zoom="8" height="1074" lat=2000 lon=1500 controls="small" showposition="yes" showregion="yes" scrollwheel="nothing">
 
+
googlemap.Circle(2000, 1600),
 
(DotGr) 2000, 1600,
 
(DotGr) 2000, 1600,
 
(DotRd) 1970, 1600,
 
(DotRd) 1970, 1600,
Line 30: Line 30:
 
<br><br>
 
<br><br>
 
</googlemap>
 
</googlemap>
 +
 +
 +
 +
// Create an object containing LatLng.
 +
var Marblemap = {};
 +
Marblemap['marble'] = {
 +
  center: new google.maps.LatLng(2000, 1600),
 +
}
 +
var marbleCircle;
 +
 +
function initialize() {
 +
  var mapOptions = {
 +
    zoom: 8,
 +
    center: new google.maps.LatLng(2000, 1600),
 +
    mapTypeId: google.maps.MapTypeId.TERRAIN
 +
  };
 +
 +
  var map = new google.maps.Map(document.getElementById('map-canvas'),
 +
      mapOptions);
 +
 +
  for (var city in citymap) {
 +
    // Construct the circle for each value in citymap. We scale population by 20.
 +
    var populationOptions = {
 +
      strokeColor: '#FF0000',
 +
      strokeOpacity: 0.8,
 +
      strokeWeight: 2,
 +
      fillColor: '#FF0000',
 +
      fillOpacity: 0.35,
 +
      map: map,
 +
      center: citymap[city].center,
 +
      radius: citymap[city].population / 20
 +
    };
 +
    cityCircle = new google.maps.Circle(populationOptions);
 +
  }
 +
}
 +
 +
google.maps.event.addDomListener(window, 'load', initialize);

Revision as of 22:35, 8 August 2013



// Create an object containing LatLng. var Marblemap = {}; Marblemap['marble'] = {

 center: new google.maps.LatLng(2000, 1600),

} var marbleCircle;

function initialize() {

 var mapOptions = {
   zoom: 8,
   center: new google.maps.LatLng(2000, 1600),
   mapTypeId: google.maps.MapTypeId.TERRAIN
 };
 var map = new google.maps.Map(document.getElementById('map-canvas'),
     mapOptions);
 for (var city in citymap) {
   // Construct the circle for each value in citymap. We scale population by 20.
   var populationOptions = {
     strokeColor: '#FF0000',
     strokeOpacity: 0.8,
     strokeWeight: 2,
     fillColor: '#FF0000',
     fillOpacity: 0.35,
     map: map,
     center: citymap[city].center,
     radius: citymap[city].population / 20
   };
   cityCircle = new google.maps.Circle(populationOptions);
 }

}

google.maps.event.addDomListener(window, 'load', initialize);