mirror of
https://github.com/marcrobledo/savegame-editors.git
synced 2025-04-28 09:05:10 +00:00
adding locations for waypoints (most)
This commit is contained in:
parent
81b3a8200b
commit
f093b51b71
@ -135,8 +135,11 @@
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
<div class="nine columns">Known locations</div>
|
||||
<div class="three columns text-right"><button onclick="visitAllLocations()">Visit all</button></div>
|
||||
<div class="seven columns">Known locations</div>
|
||||
<div class="five columns text-right">
|
||||
<button onclick="visitAllLocations()">Visit all</button>
|
||||
<button onclick="addLocationsToMap()">Add To Map</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
@ -669,7 +669,7 @@ function addToMap(data, icon){
|
||||
}
|
||||
var points = [];
|
||||
for (var i = 0; i<data.length; i++){
|
||||
var l = BOTW_Data.LOCATIONS["0x"+data[i].toString(16)]
|
||||
var l = BOTW_Data.COORDS["0x"+data[i].toString(16)]
|
||||
if (l){
|
||||
points.push({H:data[i], L:l})
|
||||
}
|
||||
@ -746,6 +746,11 @@ function addMoldugaToMap(){
|
||||
MarcDialogs.alert(n+' missing molduga added to map');
|
||||
}
|
||||
|
||||
function addLocationsToMap(){
|
||||
var n = addToMap(BOTW_Data.LOCATIONS, SavegameEditor.Constants.ICON_TYPES.STAR);
|
||||
MarcDialogs.alert(n+' missing locations added to map');
|
||||
}
|
||||
|
||||
|
||||
/* MarcTooltips.js v20170518 - Marc Robledo 2014-2017 - http://www.marcrobledo.com/license */
|
||||
var MarcTooltips=function(){return{add:function(a,b,c){var d=document.createElement("div");d.className="tooltip",d.style.position="absolute",d.style.zIndex="9000",d.style.top="0",d.style.left="0",d.innerHTML=b,document.body.appendChild(d);var e="down",f="center";c&&c.position&&/^(up|down|left|right)$/i.test(c.position)&&(e=c.position.toLowerCase()),c&&c.align&&/^(top|bottom|left|right)$/i.test(c.align)&&(("up"!==e&&"down"!==e||"left"!==c.align&&"right"!==c.align)&&("left"!==e&&"right"!==e||"top"!==c.align&&"bottom"!==c.align)||(f=c.align.toLowerCase()));var h=document.createElement("div");h.className="arrow",d.className+=" position-"+e+" align-"+f,d.className+="left"===e||"right"===e?" position-horizontal":" position-vertical",d.appendChild(h);var i=function(){var a=document.documentElement,b=(window.pageXOffset||a.scrollLeft)-(a.clientLeft||0),c=(window.pageYOffset||a.scrollTop)-(a.clientTop||0),g=this.getBoundingClientRect(),h=d.getBoundingClientRect();d.style.top="up"===e?parseInt(g.top+c-h.height)+"px":"down"===e?parseInt(g.top+c+g.height)+"px":"top"===f?parseInt(g.top+c)+"px":"bottom"===f?parseInt(g.top+c-(h.height-g.height))+"px":parseInt(g.top+c-parseInt((h.height-g.height)/2))+"px",d.style.left="up"===e||"down"===e?"left"===f?parseInt(g.left+b)+"px":"right"===f?parseInt(g.left+b-(h.width-g.width))+"px":parseInt(g.left+b-parseInt((h.width-g.width)/2))+"px":"left"===e?parseInt(g.left+b-h.width)+"px":parseInt(g.left+b+g.width)+"px",d.className+=" visible"},j=function(){d.className=d.className.replace(" visible","")};"string"==typeof a&&(a=[a]);for(var k=0;k<a.length;k++)if("string"==typeof a[k])if(/^#[0-9a-zA-Z_\-]+$/.test(a[k])){var l=document.getElementById(a[k].replace("#",""));l.addEventListener("mouseover",i,!1),l.addEventListener("mouseout",j,!1)}else for(var m=document.querySelectorAll(a[k]),n=0;n<m.length;n++)m[n].addEventListener("mouseover",i,!1),m[n].addEventListener("mouseout",j,!1);else a[k].addEventListener("mouseover",i,!1),a[k].addEventListener("mouseout",j,!1)}}}();
|
||||
|
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user