You are here

PW map with google's API

PW Map using Google API
Old Vault Category: 
scripts
Old Vault ID: 
3 859

i made a map of my PW using the google maps API to zoom in and place markers at points of interest: 

Link 


now that i've got your attention, here's how you can make your own: 

- use the minimap-export tool (http://nwntools.sourceforge.net/minimap-export.html) to extract all the area images from you module. 
- piece them all together into one big file. i used photoshop and pasted each area into a new layer (it did this by default). this let me easily resize the little maps as needed in order to make them all fit together. it took me several hours to get the hang of it and to fit some of the trickier areas together. any program that works with layers should do - heck, i even found an online one that worked well. 
- run the "create_tiles.pl" (http://www.dalakora.com/maps/create_tiles.pl) script (or whatever tiling program you like) on the completed map. this cuts up the image into many small chunks (tiles) that google maps uses when zooming in. 
- copy the tiled images and the php file i linked to over to your webserver. make sure you get your own google maps API key! 
- voila! the basic functionality is there. 

optional: 
- set up a mysql database with read only access (the create table command is at the top of the php) and input the coordinates of non-draggable map icons to denote locations. 

optional 2: 
- have a mysql database with read/write access so that users can generate map icons for everyone. 
- just drag the orange marker to the spot. it will populate the lat / lon fields at the bottom. type in a description and hit submit. 
- submitting refreshes the map and the new marker will show up 


acknowledgements: 
i borrowed heavily from some other tutorials on the web, specifically: 
Link

First Release: 
  • up
    50%
  • down
    50%