Posted March 12, 20169 yr None of the methods I have tried have given me the current light level at the block position, they seem to only be giving light levels for daytime. world.getLight(new BlockPos(player)) getLightFromNeighbors getLightBrightness how can I get the current light level? Current Project: Armerger Planned mods: Light Drafter | Ore Swords Looking for help getting a mod off the ground? Coding | Textures
March 12, 20169 yr Author I've tried that one, it gives the same value at night as it does during the day. Current Project: Armerger Planned mods: Light Drafter | Ore Swords Looking for help getting a mod off the ground? Coding | Textures
March 12, 20169 yr Then World#getSkyLightSubtracted() IIRC. Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable. If you think this is the case, JUST REPORT ME. Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice. Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked. DO NOT PM ME WITH PROBLEMS. No help will be given.
March 12, 20169 yr Mobs check the light level of their spawn location in EntityMob#isValidLightLevel , you should be able to adapt this to your needs. Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.