mirror of
https://github.com/Azgaar/Fantasy-Map-Generator.git
synced 2025-12-22 12:01:23 +01:00
well, I converted Biomes to have a class instead of a series of arrays. Limited testing has been done but it works
This commit is contained in:
parent
7a06e0bdd4
commit
d9df7c2f15
10 changed files with 144 additions and 96 deletions
|
|
@ -104,7 +104,7 @@ function showMapTooltip(point, e, i, g) {
|
|||
if (layerIsOn("togglePrec") && land) tip("Annual Precipitation: "+ getFriendlyPrecipitation(i)); else
|
||||
if (layerIsOn("togglePopulation")) tip(getPopulationTip(i)); else
|
||||
if (layerIsOn("toggleTemp")) tip("Temperature: " + convertTemperature(grid.cells.temp[g])); else
|
||||
if (layerIsOn("toggleBiomes") && pack.cells.biome[i]) tip("Biome: " + biomesData.name[pack.cells.biome[i]]); else
|
||||
if (layerIsOn("toggleBiomes") && pack.cells.biome[i]) tip("Biome: " + biomesData.biomeList[pack.cells.biome[i]].name); else
|
||||
if (layerIsOn("toggleReligions") && pack.cells.religion[i]) {
|
||||
const religion = pack.religions[pack.cells.religion[i]];
|
||||
const type = religion.type === "Cult" || religion.type == "Heresy" ? religion.type : religion.type + " religion";
|
||||
|
|
@ -146,7 +146,7 @@ function updateCellInfo(point, i, g) {
|
|||
infoBurg.innerHTML = cells.burg[i] ? pack.burgs[cells.burg[i]].name + " (" + cells.burg[i] + ")" : "no";
|
||||
const f = cells.f[i];
|
||||
infoFeature.innerHTML = f ? pack.features[f].group + " (" + f + ")" : "n/a";
|
||||
infoBiome.innerHTML = biomesData.name[cells.biome[i]];
|
||||
infoBiome.innerHTML = biomesData.biomeList[cells.biome[i]].name;
|
||||
}
|
||||
|
||||
// get user-friendly (real-world) height value from map data
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue