diff options
Diffstat (limited to 'js/mapspecs.js')
-rw-r--r-- | js/mapspecs.js | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/js/mapspecs.js b/js/mapspecs.js index 0ea99db..2387a00 100644 --- a/js/mapspecs.js +++ b/js/mapspecs.js @@ -826,6 +826,17 @@ function displayMap(mapid, divID, goalSize, solution, moves, challengeMap, isThu });
}
+var Tile = {
+"o" : "Open",
+"s" : "Start",
+"f" : "Finish",
+"c" : "Checkpoint",
+"r" : "Rock",
+"t" : "Teleport In",
+"u" : "Teleport Out",
+"p" : "Unbuildable",
+"x" : "Single-Path-Rock"};
+
//Map as object. If target width is NULL or False, default width is used.
function mapAsHTML(map, targetWidth, demo) {
@@ -867,7 +878,7 @@ function mapAsHTML(map, targetWidth, demo) { mapgrid += "<div style='float:left; width:"+tileWidth+"px; height:"+tileWidth+"px; ' class='mapcell "+type+value+"' title='Position: "+x+","+oldy+"' id='"+idHandle+"' onClick='grid_click(this)' >";
mapgrid += "<div id='child_"+idHandle+"' class='child'></div></div>";
} else {
- mapgrid += "<div style='float:left; width:"+tileWidth+"px; height:"+tileWidth+"px; ' class='mapcell "+type+value+"' title='Position: "+x+","+oldy+"' id='"+idHandle+"' >";
+ mapgrid += "<div style='float:left; width:"+tileWidth+"px; height:"+tileWidth+"px; ' class='mapcell "+type+value+"' title='"+Tile[type]+" "+value+" On: "+x+","+oldy+"' id='"+idHandle+"' >";
mapgrid += "<div id='child_"+idHandle+"' class='child'></div></div>";
}
}
@@ -931,10 +942,7 @@ function mapThumbnailHTML(map, targetWidth, isActive) { height = tileWidth * map.height;
var mapgrid = '';
-
-
var r = '';
- //r += "<div class='mapThumbnail"+mapClass+"' title='"+toolTip+"'; onclick='displayMapScores("+map.ID+")'>";
r += map.name;
mapgrid += '<div class="map" style="width:'+width+'px; height:'+height+'px">';
@@ -949,9 +957,7 @@ function mapThumbnailHTML(map, targetWidth, isActive) { }
}
mapgrid += '</div>';
-
r += mapgrid;
- //r += '</div>';
return r;
}
|