Jump to content

  • Curse Sites
Become a Premium Member! Help
Latest News Article

Light Level Overlay

1.6.4 light level vanilla forge

  • Please log in to reply
214 replies to this topic

#1

4poc
    4poc

    Carpenter

  • Members
  • 49 posts
  • Minecraft: 4poc

Posted 04 August 2012 - 02:38 AM

Posted Image

This Minecraft mod visualizes the light levels emitted by torches, glowstone and alike directly on top of blocks, this is helpful to quickly identify areas where mobs can spawn. It shows the light level of the airblock above the block the number is drawn onto, this is the block that is considered for mob spawning, light level 7 or below allows mobs to spawn.
Press F9 (customizable) to toggle the overlay.
Press Shift + F9 (customizable) to open a configuration GUI. (since v0.23)

Download
The source code is available at Github, its 3-clause BSD licensed. Older versions can be found here.

Current development builds can be obtained directly from my jenkins build server.

Alternatives

This is not the only mod that does this sort of thing, you might also want to checkout these other mods that do similar things ;)


Installation Forge

You must use the Forge version if you want to use this together with other mods, like optifine. Forge allows it to write minecraft mods that are compatible with each other, even when they modify the same part of minecraft. In case of this mod, the rendering is modified and therefore ordinarily incompatible with any other mod that also effects rendering (like optifine). Forge allows compatibility because it provides the necessary code (the RenderWorldLast event) to make it compatible. I don't provide a ModLoader version because ModLoader doesn't have this or an equivalent functionality, fortunately forge is compatible with ModLoader mods.

  • If not already: Download and install forge using the installer.
  • Copy the lloverlay_*-forge.zip file to your ~/.minecraft/mods/ or %appdata%/.minecraft/mods directory.

Installation Vanilla

Vanilla means an unmodified minecraft version. This does not work with optifine for instance, because it also modifies a class file. The new vanilla launcher (since 1.6) allows you to easily switch between different versions. If you use the vanilla launcher, I would recommend creating a new version (with the mod installed) that you can then assign to an extra profile, that would allow you to switch between vanilla/modded:

  • First locate your versions directory in ~/.minecraft/versions or %appdata%/.minecraft/versions.
    There should be a 1.6.1 directory with the latest version.
  • Copy the 1.6.1 directory to 1.6.1-lloverlay or something, this will be the new name of the version.
  • Now you need to rename all files in the 1.6.1-lloverlay directory to match the version name. Rename all 1.6.1-lloverlay/1.6.1* to 1.6.1-lloverlay/1.6.1-lloverlay*.
  • You also need to change the version name in the 1.6.1-lloverlay/1.6.1-lloverlay.json file. Open the json file with an editor (vi/emacs/notepad) and change the line
    "id": "1.6.1",
    to
    "id": "1.6.1-lloverlay",
  • Now to actually install the mod you need to replace the contents of the jar file with the mod contents.
    Unpack the (renamed) 1.6.1-lloverlay.jar file someplace.
  • Remove the META-INF folder from the extracted files.
  • Unpack the lloverlay_*.zip file within, override anything.
  • Pack the folder again in a zip file named 1.6.1-lloverlay.jar
  • and replace it with the /versions/1.6.1-lloverlay/1.6.1-lloverlay.jar file.
  • Now you can start the launcher and configure your profiles, thats quite easy to do, the 1.6.1-lloverlay version should appear under the "Use version" dropdown in the profile editor. You can also create a new profile and assign it the -lloverlay version.

Customization

Since v0.23 you can just use the GUI (open with Shift+F9) to change the settings!

After you played with lloverlay the first time a ~/.minecraft/config/lloverlay.properties file is created with all default configuration options:
  • hotkey: keycode that toggles the overlay (list of possible values)
  • debug: activates debug messages
  • renderChunks: distance in chunks in each direction the overlays are drawn, decrease if you run into performance problems
  • textureRow: the textures provided (lightlevel.png) can include multiple "styles" or themes, here you can select which row should be drawn (0 = first row, 1 = second row, ...). Each block texture is 16x16 pixel. Feel free to add your own styles and sent it to me I might include them in the next version! See all 3 currently included ones here.
  • generateInterval: the interval in milliseconds (250 = 1/4 second) in which the lightlevel data are gathered (if you place a torch its at least 250 ms till the overlays are updated), increase if you run into performance problems
  • showLightlevelUpto: you can set the level up-to the overlay should be drawn.
  • drawNonSpawnable: if set to true draw the lightlevel on halfslabs/farmland/glass where mobs can't spawn. Is currently unused (as of >v0.16)
  • useSkyLightlevel: set to true for light levels effected by daylight (all surface blocks 15 light level, unfortunately currently also at night times)
  • renderer: renderer to use, can be set to "auto" (default), "fast" or "vanilla"

Changelog
v0.23 [25.09.2013]
  • added a settings GUI:
    Spoiler:
  • remove hotkey R for reload, there is now a button for that in the settings GUI
  • removed config option renderDistance, replaced with renderChunks (same but in chunks instead of blocks)
v0.22 [23.09.2013]
  • bugfixes: properly render at y=0, fix blending in vanilla
v0.20 [23.09.2013]
  • updated for latest minecraft 1.6.4
  • new faster renderer using VBOs + old original vanilla (see "renderer" config option)
v0.18 [12.07.2013]
  • updated for latest forge version (9.10.0.789)
v0.17 [09.07.2013]
  • fixes a bug with the new per chunk overlay collector, that caused (silent) crashes at low levels
v0.16 [09.07.2013]
  • nonSpawnable is deprecated as of now, levels are always shown on any surface (this will change somewhat in the future when the indication spawnable/nonspawnable is properly separated)
  • draw overlays on leaves
  • (bugfix!) show correct block light level instead of two above blocks
  • (bugfix!) revert some rendering changes
  • (bugfix!) draw overlay below torches/etc. again
v0.15 [07.07.2013] (No changes, compatibility release only)
  • Update for 1.6.2
v0.14 [07.07.2013]
  • The light levels are now gathered in a thread.
  • Rendering code separated.
    I need to optimize this more, but its a good start I think.
  • hotkey deactivated if in ingame menu
v0.13 [06.07.2013] (No changes, compatibility release only)
  • Updated MCP & Forge
v0.12 [01.07.2013] (No changes, compatibility release only)
  • Update for 1.6.1
v0.11 [04.06.2013]
  • Update for 1.5.2
  • Change config location to minecraft/config/lloverlay.properties
v0.10 [03.04.2013] (No changes, compatibility release only)
  • Update for 1.5.1
v0.9 [19.12.2012] (No changes, compatibility release only)
  • Update for 1.4.6
v0.9 [17.11.2012]
  • Update for 1.4.4
  • Press F9(or customized hotkey)+R to reload the configuration file
  • New config option: drawNonSpawnable, if set to true draw the lightlevel on halfslabs/farmland/glass where mobs can't spawn
  • Replaced the showIlluminated option for showLightlevelUpto, you can set the level up-to the overlay should be drawn.
  • New config option: useSkyLightlevel, set to true for light levels effected by daylight (all surface blocks 15 light level, unfortunately currently also at night times)
v0.8 [23.10.2012] (Compatibility Release Only)
  • Update for Preview 1.4
v0.7 [16.08.2012] (Compatibility Release Only)
  • Update for 1.3.2
  • *I added a forge version with this release: This is for a beta version of forge but I thought I release it anyways, I think Optifine is not yet compatible with it through. I encountered a bug with this version where the light level isn't drawn on-top of wood half-slabs I will try to fix this for the next version however.
v0.6 [15.08.2012]
  • Render on-top of snow toppings.
v0.5 [08.08.2012]
  • Another small optimization in cache generation
  • Draw overlay on all mob-spawnable blocks. (as pointed out by Mochnant, thanks)
  • New configuration option showIlluminated allows to hide the overlay on well-lit blocks.
  • Small changes in texture file. See all 3 currently included ones here.
v0.4 [06.08.2012]
  • Optimization mostly in cache generation (simplified the algorithm that selects the blocks to draw onto)
  • As suggested by zfz the texture file now contain textures that only show a red square in the middle of blocks, where mobs are capable of spawning, to activate this set textureRow to 1.
v0.3 [04.08.2012] (Initial Public Release)
apoc.cc · mods: light level overlay · bounding box outline

Register or log in to remove.

#2

Contagiousrabbit

Posted 04 August 2012 - 03:13 AM

Downloading right now...literally came onto the forums ONLY looking for a mod to do just this.  So awesome man.

#3

Yopok3
    Yopok3

    Tree Puncher

  • Members
  • 29 posts
  • Location: Australia
  • Minecraft: Yopoke

Posted 04 August 2012 - 04:16 AM

nice mod, very useful :)
go suck a bag of dicks

#4

ZDeztroyerz
  • Minecraft: ZDeztroyerz

Posted 04 August 2012 - 06:07 AM

Wow this is awesome to make sure mobs can't spawn
My Youtube Is http://www.youtube.com/ZDeztroyerz
And I'm a fan of Toonami

#5

zfz
    zfz

    Gold Miner

  • Members
  • 377 posts

Posted 04 August 2012 - 06:17 AM

Cool stuff. I just finished the wall for a village and wanted to find exactly this kind of mod. I think there was another one that just showed a square as opposed to numbers, and only on blocks where mobs could spawn.

How about a texture where only 0-7 get a square of about 5x5 in the middle?

I'm not sure exactly how high a row is for the texture png, perhaps put that in your description?
Posted Image

#6

4poc
    4poc

    Carpenter

  • Members
  • 49 posts
  • Minecraft: 4poc

Posted 04 August 2012 - 06:37 AM

View Postzfz, on 04 August 2012 - 06:17 AM, said:

Cool stuff. I just finished the wall for a village and wanted to find exactly this kind of mod. I think there was another one that just showed a square as opposed to numbers, and only on blocks where mobs could spawn.

Glad you liked it:) Yes there is something in the Zombe's modpack that does something similar (didn't test it myself).

Quote

How about a texture where only 0-7 get a square of about 5x5 in the middle?

I'm not sure exactly how high a row is for the texture png, perhaps put that in your description?

Thats possible sure, the row is already multiplied by 16 (height in pixel) so just set it to 3 for instance if you want the 4th row (it starts at 0) to show. The size of each tile is 16x16 pixel.
Yeah I try to make this more clear in the description.
apoc.cc · mods: light level overlay · bounding box outline

#7

EmpireGaming

Posted 04 August 2012 - 11:25 AM

nice mod



#8

FreshMiner
  • Minecraft: TheFreshMiner

Posted 04 August 2012 - 05:30 PM

Hey man, I took the time to make a great video for this mod. Maybe make it the official one on your forum post?


Posted Image

#9

Toilet_Papered
    Toilet_Papered

    The Meaning of Life, the Universe, and Everything...

  • Members
  • 42 posts
  • Minecraft: Toilet_Papered

Posted 05 August 2012 - 05:29 PM

Is there anyway to not have 11 errors when installing using magic launcher?
Posted Image

#10

Mochnant
    Mochnant

    Tree Puncher

  • Members
  • 18 posts

Posted 06 August 2012 - 10:16 PM

Great mod, came looking for something like this.  One thing I noticed was it doesn't seem to paint on top of upside down slabs where I believe mobs can now spawn (not sure about upside down stairs).

EDIT:

Might I suggest a green circle for safe plus the red squares from textureRow=1 to be a new entry as textureRow=2?

Posted Image

Posted Image

#11

4poc
    4poc

    Carpenter

  • Members
  • 49 posts
  • Minecraft: 4poc

Posted 08 August 2012 - 01:03 AM

View PostMochnant, on 06 August 2012 - 10:16 PM, said:

Great mod, came looking for something like this.  One thing I noticed was it doesn't seem to paint on top of upside down slabs where I believe mobs can now spawn (not sure about upside down stairs).

Thanks for pointing that out, totally forgot about that. Mobs can spawn on upside-down slabs/stairs but also on workbench, furnace, etc. I released a new version (v0.5) that displays the overlay also on those blocks.

Quote

Might I suggest a green circle for safe plus the red squares from textureRow=1 to be a new entry as textureRow=2?

Good idea! I made it a little bit more flexible: The textureRow=1 now includes the green circles as well and I made a new configuration option "showIlluminated" with which you can select to draw the green tiles or not. Set showIlluminated=false if you don't want to see the green circles or numbers (depending on textureRow)
apoc.cc · mods: light level overlay · bounding box outline

#12

Mochnant
    Mochnant

    Tree Puncher

  • Members
  • 18 posts

Posted 08 August 2012 - 05:36 PM

View Post4poc, on 08 August 2012 - 01:03 AM, said:

Thanks for pointing that out, totally forgot about that. Mobs can spawn on upside-down slabs/stairs but also on workbench, furnace, etc. I released a new version (v0.5) that displays the overlay also on those blocks.

Fantastic, that will help me hunt down those last few dark corners.

View Post4poc, on 08 August 2012 - 01:03 AM, said:

Good idea! I made it a little bit more flexible: The textureRow=1 now includes the green circles as well and I made a new configuration option "showIlluminated" with which you can select to draw the green tiles or not. Set showIlluminated=false if you don't want to see the green circles or numbers (depending on textureRow)

A good solution.

On a slightly different note, have you considered some form of server based plugin that would allow anyone to use the mod while playing SMP on that server?

#13

xelrix
    xelrix

    Stone Miner

  • Members
  • 80 posts

Posted 08 August 2012 - 05:49 PM

i dont know what the ava class is for but it seems like it conflicts with optifine's ava.class too.
my priority would be optifine but this mod seems too useful to pass. will it be okay if i overwrrite this mod's ava with optifine's?



edit: looks like this mod really need that ava.class.

could some body tell me what does the ava.class is needed for (what does it do exactly?) so i could make sure that i dont compromise optifine's function if i decided to replace optifine's ava?

#14

JonathanTheBlack

Posted 08 August 2012 - 08:00 PM

Hrm, not compatible with OptiFine and it doesn't seem compatible with ModLoader. Much as I'd like to use this just to see how lighting levels work... gonna have to pass.

#15

-+- Archer -+-
  • Location: In a tree, hunting you down ^^
  • Minecraft: Archer6621

Posted 08 August 2012 - 10:45 PM

Make it compatible with the common mods (modloader/optifine/whatever) and I'll provide you with an endless supply of diamonds :P
Posted Image
Click on the image to visit my Soundcloud profile!

#16

4poc
    4poc

    Carpenter

  • Members
  • 49 posts
  • Minecraft: 4poc

Posted 09 August 2012 - 12:10 AM

I definitely want to make it compatible with Optifine I use it myself, however I wasn't able to make it work with modloader (not sure if its even possible). But I will definitely try to get it work with forge as soon as they are ready for 1.3.1.
apoc.cc · mods: light level overlay · bounding box outline

#17

Mochnant
    Mochnant

    Tree Puncher

  • Members
  • 18 posts

Posted 09 August 2012 - 02:20 PM

Any chance it could draw on top of snow?  I've got a fortress in the icy wastes and can't tell the lighting without destroying the snow first on the battlements.

#18

damunzy
    damunzy

    Coal Miner

  • Members
  • 122 posts
  • Location: Jersey Shore, NJ, USA
  • Minecraft: damunzy

Posted 09 August 2012 - 04:33 PM

I put the contents of the zip file into the minecraft.jar and disabled OptiFine in MagicLauncher but when I run the game the lloverlay.properties file is not created. I have the following mods installed:
Spoiler:
Any idea what could be causing the problem? Oh, I also have [1.3.1]ModLoader and [1.3.1]ModLoaderMP-1.0 directly in the jar in that order before your was added to the jar. Thanks in advance for any help! :)

View Post4poc, on 04 August 2012 - 02:38 AM, said:


Customization

After you played with lloverlay the first time a ~/.minecraft/lloverlay.properties file is created with all default configuration options, feel free to modify any of those:
  • hotkey: keycode that toggles the overlay (list of possible values)
  • debug: activates debug messages
  • drawDistance: distance in blocks in each direction the overlays are drawn, decrease if you run into performance problems
  • textureRow: the textures provided (lightlevel.png) can include multiple "styles" or themes, here you can select which row should be drawn (0 = first row, 1 = second row, ...). Each block texture is 16x16 pixel. Feel free to add your own styles and sent it to me I might include them in the next version! See all 3 currently included ones here.
  • generateInterval: the interval in milliseconds (250 = 1/4 second) in which the lightlevel data are gathered (if you place a torch its at least 250 ms till the overlays are updated), decrease if you run into performance problems
  • showIlluminated: whenever or not the overlay should be drawn on well-lit blocks.

“There are 10 types of people in the world. Those that understand binary and those that do not.” – anonymous computer geek
01100100 01100001 01101101 01110101 01101110 01111010 01111001

#19

Helzar
    Helzar

    Out of the Water

  • Curse Premium
  • Curse Premium
  • 2 posts

Posted 10 August 2012 - 12:42 AM

Just thought I'd add some indicators...
The icons/colours are:
  • Red Cross - Mobs spawn at this level
  • Yellow Rod - Blaze spawn at this level
  • Gray Spider - Spiders are aggresive at this level
  • Dark Green Grass - Grass will spread from this level
  • Brown Mushroom  - Mushrooms will grow at this level
  • Light Green Flower - Flowers/Trees/Crops will grow at this level
  • Light Blue Line - Ice & snow remain frozen at this level
www.happyasapigin.com/minecraft/lightlevel.png
(sorry, my .png doesn't seem to post - I'll keep trying)

The grey box line is simply my guides for entering a new line of icons.

I'm not sure how well the idea works, because I'm wrestling with making the mod work with my 1.3.1.
I would love to see a screenshot if someone takes one.
:-(

#20

4poc
    4poc

    Carpenter

  • Members
  • 49 posts
  • Minecraft: 4poc

Posted 15 August 2012 - 07:57 AM

View PostMochnant, on 09 August 2012 - 02:20 PM, said:

Any chance it could draw on top of snow?  I've got a fortress in the icy wastes and can't tell the lighting without destroying the snow first on the battlements.
I just released a new version (v0.6) that fixes this :)
apoc.cc · mods: light level overlay · bounding box outline