Make block react when arrow hits it

Started by LuckyBacon on

Topic category: Help with MCreator software

Joined Jan 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make block react when arrow hits it

How can i make a block react and do things when an arrow (or bullet) is shot at it? For example, emit a redstone signal?

Joined Jan 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
hmm, i dont think this is…
Tue, 09/17/2019 - 02:25

hmm, i dont think this is possible.

You might be able to achieve…
Tue, 09/17/2019 - 09:26

You might be able to achieve this using on entity collides with block trigger and check if the entity is subtype of arrow and if it is, execute your desired action.

Joined Jan 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
There's no "Entity Collides…
Tue, 09/17/2019 - 22:52

There's no "Entity Collides With Block". And "Entity Collides In Block" wont do.
forgot to mention, this is for MC 1.12.

Joined Jan 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Since i cannot edit my post,…
Tue, 09/17/2019 - 23:24

Since i cannot edit my post, ill add one.
There is also no "arrow" for subtype. And if i try to change it to EntityArrow in the code, i get an error pointing at it.

If you add it in code, make…
Wed, 09/18/2019 - 06:20

If you add it in code, make sure to import it or press Ctrl + W for MCreator to import it for you.

I forgot that 1.9.0 is missing some entities from the list. All entities will be added in MCreator 1.9.1.

Joined Jan 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Yeah, i got it to compile…
Wed, 09/18/2019 - 23:34

Yeah, i got it to compile.
But it is not working. Block says "Entity Collides In Block", but in the code, it says "onEntityCollidedWithBlock" 
"With". Problem is, i need my block to be solid, and this will only work if i check the "pass through" box.