Commands (often called “slash commands”) are a great way to adjust settings in your world. While many options are also available through various menus (including the Classroom Mode interface), there are certain settings only accessible through these commands. In this article, you’ll learn how commands are set up through common variables like targeting and coordinates, and we will even go through a few essential commands to get you started.
How to Use
Customizing worlds with commands
Exclusive Commands for Education Edition
Commands, also referred to as “Slash Commands”, are entered via Minecraft’s chat window, which is displayed by pressing the T key (default), enter key, or / key. Slash Command entry features a predictive text system that helps players find and use commands from the list. To use most Commands in game, Activate Cheats must be enabled from the Game Settings menu.
Using this while typing a command will auto-complete that command or arguments for it.
Using the / key will also enter the forward slash that commands require as a prefix into the chat window, so it is a useful shortcut.
↑ and ↓
The arrow keys enter the previously executed command.
This cycles through possible commands or arguments, and can be used to auto-enter the coordinates of the block looked at before entering chat.
In most commands where a player may be specified as an argument, it is possible to “target” one or more players instead of specifying players by name. For example, the teleport command has options for not just destination, but other players, and rotation coordinates.
Random player(s) (a list will appear below of players currently in the world)
In the above picture, did you notice the destination variable? For some commands, location is required through X, Y, Z coordinates.
Commands recognize two types of locations, true location, and relative location.
When you load into the game, you do not automatically start at 0,0,0. The easiest way to see the location where you are is to use Show Coordinates. (Remember: Cheats must be turned on to use this option.)
With regards to coordinates, rotation is optional, so we will cover it in a “Commands In Depth” section (currently unavailable, but coming soon).
You can also use negative values for tildes and relative coordinates. Feel free to experiment!
You can customize the world and in some cases, alter the individual experience within it for your users. While you can select these options as you are creating the world, you can also change those options once you are in the world.
Syntax: /difficulty (string)
This is what it looks like in the game settings menu.
Hostile mobs are allowed to spawn, and as the name suggests, provide less damage than on normal difficulty.
Hostile mobs are allowed to spawn, and as the name suggests, provide more damage than on normal difficulty.
Hostile mobs can spawn, but deal standard damage levels.
Hostile mobs do not spawn naturally, and they do not deal damage.
Unlike Creative or Survival mode, you cannot set this per player.
Syntax: /immutableworld (value)
Immutable world works just like Adventure mode in other editions of Minecraft, but is exclusive to Education Edition. It must be set by an operator of the world, and cannot be set per player. Adventure mode lets you interact with blocks but not destroy them.
Syntax: /gamemode (string) (target)
This adjusts the same game setting as this option in the game settings menu.
Creative mode removes the survival elements and allows players to easily create and destroy structures and mechanisms. Unlimited building materials are provided.
In this mode, players have to gather all their materials to build, craft, and gain experience points.
By using the menu option, it will set the option for the entire world. By using commands in the world, you can set game mode per player.
/gamerule (allowdestructiveobjects, allowmobs, globalmute options)
Syntax: /gamerule (string) (value)
You can also set these via the Classroom Mode interface.
Typing /help will bring up a full list of current commands available in Minecraft: Education Edition. Here are specific commands that are either unique to or may work differently in Minecraft: Education Edition.
Syntax: /ability (target) (ability) (true or false)
These two commands will attempt to launch and connect you to Classroom Mode and Code Connection, provided you have them installed, of course. As there are no additional arguments needed, just enter the above command and press return.
If you do not have the required application installed, you will see an error window similar to this (macOS version is displayed for reference):
To resolve, download the needed application, install, and try again.
/clearfixedinv and /setfixedinvslot
Syntax: /setfixedinvslot (slot number) (item name) (quantity)
Minecraft: Education Edition has up to three extra slots that can be used.
These special slots also possess special abilities such as adding unlimited durability or quantity of items placed within them. To toggle what item is active in the extended hotbar, use the “0” (zero) key on your keyboard (see other Minecraft controls).
Only an Operator can remove or place items into them. These slots must be created and equipped through commands.
Items in these slots cannot be dropped or destroyed by students. (The camera will not disappear.)
A common set of commands to set up a new world is as follows:
You can put anything in these slots, for example, a stick, or even a baked_potato. Did you mean to give someone a healthy carrot instead of a cake? Just try the command again with the item you meant to use (/setfixedinvslot 1 carrot) and it will overwrite what is currently in the slot.
Need to remove those slots? Use /clearfixedinv to remove the items. Please note that this command will clear all the slots at once, and you cannot remove a single fixed inventory slot.
Updated December 27, 2017