diff --git a/src/main/java/org/dynmap/bukkit/BukkitWorld.java b/src/main/java/org/dynmap/bukkit/BukkitWorld.java index dbf4ab0a..d83b956f 100644 --- a/src/main/java/org/dynmap/bukkit/BukkitWorld.java +++ b/src/main/java/org/dynmap/bukkit/BukkitWorld.java @@ -36,6 +36,20 @@ public class BukkitWorld extends DynmapWorld { this.env = env; skylight = (env == World.Environment.NORMAL); new Permission("dynmap.world." + getName(), "Dynmap access for world " + getName(), PermissionDefault.OP); + // Generate non-default environment lighting table + switch (env) { + case NETHER: + { + float f = 0.1F; + for (int i = 0; i <= 15; ++i) { + float f1 = 1.0F - (float)i / 15.0F; + this.setBrightnessTableEntry(i, (1.0F - f1) / (f1 * 3.0F + 1.0F) * (1.0F - f) + f); + } + } + break; + default: + break; + } } /** * Set world online diff --git a/src/main/resources/configuration.txt b/src/main/resources/configuration.txt index 205a3038..fbedd7ab 100644 --- a/src/main/resources/configuration.txt +++ b/src/main/resources/configuration.txt @@ -219,6 +219,10 @@ enabletilehash: true # Optional - enable smooth lighting by default on all maps supporting it (can be set per map as lighting option) smooth-lighting: true +# Optional - use world provider lighting table (good for custom worlds with custom lighting curves, like nether) +# false=classic Dynmap lighting curve +use-brightness-table: true + # Optional - render specific block IDs using the texures and models of another block ID: can be used to hide/disguise specific # blocks (e.g. make ores look like stone, hide chests) or to provide simple support for rendering unsupported custom blocks block-id-alias: