Block that breaks if it is not placed on a specific block

Started by Rain2 on

Topic category: Help with Minecraft modding (Java Edition)

Joined Jun 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Block that breaks if it is not placed on a specific block

Basically, I am trying to make a block that will break and drop itself if it it is placed on an incorrect block. For example, if I were to place it on dirt or stone, it would break but if I placed it on an ore it would place normally. My code for some reason breaks the block no matter what block you place it on. Any help would be appreciated!

Joined Mar 2014
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Try adding a block placement…
Tue, 06/21/2022 - 12:38

Try adding a block placement condition to your block. In the procedure, add the dark cyan report block found in Minecraft components and then add to it a script to check if the block below is an ore

Joined Jun 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Could you give me an example…
Tue, 06/21/2022 - 18:00

Could you give me an example? I'm not a sure what you mean by that...