Jump to content

Detect Lightning Bolt impact with block


Recommended Posts

I am programming a block which should use the energy of a lightning bolt, but I am unable to detect such impacts.

All entity detection methods from Block class aren't able to detect them, but I can detect every other kind of Entity.

Is there any possibility for that?

Thanks for answers!

Link to comment
Share on other sites



I think a Lightning bolt doesn't really behave like other entities do, it's more a placeholder and doesn't perform collision detection in the same way.  I think the best you can probably do is to detect when it's spawned using (eg) EntityConstructing event, then look at its x,y,z to find the block that it is spawning at.



Link to comment
Share on other sites

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.

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.


  • Create New...

Important Information

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