Jump to content

Recommended Posts

Posted

Is there a way to check if the player is on a shadow or dark place? The only option i could come up with is to check if there's a block above the player, but i want to know if there's better options.

Posted

if you have a location (BlockPos type, get it from your entity) and a world (Level, also available in any entity), ask the world for light level at that location. you can also ask if the "block" at location can see the sky, etc.

  • Thanks 1
Posted
11 hours ago, MFMods said:

if you have a location (BlockPos type, get it from your entity) and a world (Level, also available in any entity), ask the world for light level at that location. you can also ask if the "block" at location can see the sky, etc.

that's a great idea, thanks! I'll try that.

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.