Make a certain block unplaceable?

Make a certain block unplaceable? - Content female customer with long curly hair wearing casual outfit sitting at wooden table with netbook in classic interior restaurant while making online order

I was wondering if there is a way to make a block such as bedrock or obsidian unplaceable in a certain area, because I wanted to give players creative mode for a game, but I don't want them to use bedrock or obsidian in their creations. Is there any way to make a block unplaceable using commands?



Best Answer

I just realized that the easiest way to do this is to have a fill clock setting off two command blocks that replace all bedrock/obsidian with air.




Pictures about "Make a certain block unplaceable?"

Make a certain block unplaceable? - White shabby concrete wall with cracked stucco
Make a certain block unplaceable? - Unrecognizable crop African American female pouring essential oil in glass bottle while making liquid incense at table
Make a certain block unplaceable? - Man in Black Jacket Sitting on Block



How do you make a block Unplaceable in Minecraft?

/testfor @a[r=10] {Inventory:[{Slot:0b,id:"minecraft:obsidian"}]} If you wanted to use this method you would have to testfor slots 0-8, just change the zero. increasing the radius will increase the area you wish them not to place those blocks.

How do you set blocks in creative mode?

For Minecraft Bedrock Edition, you'll need to do the following:
  • Enable cheats in your world or Realm settings.
  • Turn on Creative Mode in your world or Realm settings.
  • Open the chat box and enter \u201c/give [your username] command_block\u201d
  • Place the block where you want it.




  • i made unplaceable block without mods (not clickbait)




    Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

    Images: Yan Krukov, Tatiana Syrikova, Anna Shvets, Lisa