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

Started by Rain2 on

Topic category: Help with modding (Java Edition)

Last seen on 12:25, 23. Jun 2022
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!

Last seen on 10:58, 9. Jul 2023
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

Last seen on 12:25, 23. Jun 2022
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...

Last seen on 11:34, 9. Oct 2022
Joined May 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
(No subject)
Sat, 07/09/2022 - 15:37

in the 'when block is placed' trigger in 'Triggers' section

Last seen on 11:34, 9. Oct 2022
Joined May 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
(No subject)
Sat, 07/09/2022 - 15:38

this code