How do I make no one able to break blocks?

How do I make no one able to break blocks? - Crop young lady breaking eggs in flour for dough

I made a Kit PvP world and when my friends play they destroy everything. I don't want to keep rebuilding everytime.

Is there a command with which they can't break any blocks anymore ?



Best Answer

Use Adventure Mode (/gamemode 2), this way players aren't able to destroy anything except things like vines or tall grass but they are able to do other actions like opening chests or fighting with swords.

The command to set everyone to Adventure mode is: /gamemode 2 @a




Pictures about "How do I make no one able to break blocks?"

How do I make no one able to break blocks? - From above of empty mug and coffee beans on wooden table prepared for making coffee
How do I make no one able to break blocks? - Person breaking egg to flour for pastry
How do I make no one able to break blocks? - High angle of crop anonymous chef breaking eggs for cooking dough at table with flour



How do I make it so I can only break certain blocks?

Players can set the gamerule mobGriefing to false to prevent any mob from breaking blocks.



How to make Not breaking Blocks | Minecraft Tutorial | Gone wrong!!




More answers regarding how do I make no one able to break blocks?

Answer 2

But, if you still want to let players place things, that does not work. Another way is to give everyone mining fatigue by using the following:

/effect player effect seconds amplifier

For example:

/effect @a mining_fatigue 100 100, and have a clock running with command blocks with that continence.

Here's a way to hide the text that says that it did it, Do /gamerule DoCommandOutput False

Answer 3

If you’re on pc or pe edition you can put the permission on visitor so other players cannot break blocks,or open chests.

Answer 4

You can set each player into adventure mode /gamemode a. This makes them unable to break blocks.

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

Images: Katerina Holmes, Ryutaro Tsukata, Klaus Nielsen, Klaus Nielsen