In Minecraft, you are able to use commands to do certain actions. Commands are advanced features which you can activate by typing certain strings of text. You are able to enter commands through the chat window which is displayed by pressing the T key or if you are in Java Edition, I Key.
You may need the commands that you are able to use in singleplayer of Minecraft. Well, there are a lot of commands actually. So, in the list below, we just give you some of the commands for singleplayer.
According to Minecraft Wiki, here are some of the commands for single player in Minecraft.
syntax (usage): /help <command>
It will show the syntax of a command.
- /whisper (/msg/tell)
syntax (usage): /whisper <player> <message>
It will tell a private message to <player>.
syntax (usage): /ability <player><grant>/ revoke> <ability>
This command will give or revoke an ability to a player such as fly or world builder.
However, this command is only available on Minecraft: Education Edition.
Syntax (usage): /advancement <grant |revooke|test> <player> <advancement> [criterion].
It will give or take an advancement from a player or test if a player has an advancement.
Syntax (usage): /clear <player> [item ID] [DV] [maximum amount taken] [DataTag]
It will clear [Item ID] from <player> if [DV] and [DataTag] match the one in the inventory. If [Item ID] is not specified, it will erase the inventory of a player completely.
Syntax (usage): /clone <x> <y> <z> <dx> <dy> <dz> <x2> <y2> <z2> [type].
It will copy the area within the first two sets of coordinates and pastes it at the third.
Syntax (usage): /debug <start – stop>
It will begin profiling a debug session or stop one.
Syntax (usage): /defaultgamemode <survival – creative – adventure – spectator>
It will set the server’s default game mode for when players join for the first time.
Syntax (usage): /difficulty <peaceful – easy – medium – hard>
It will change the difficulty of the server.
Syntax (usage): /effect <player> <effect_name> [Time(seconds)] [amplifier] [(show particles) true – false]
It will give <player> <effect ID> [amplifier] for [Time] seconds.
Syntax (usage): /enchant <player> <enchantment_name> [Enchantment level]
It will enchant the item in <player>s hand with <enchantment_name>
Syntax (usage): /execute <as – at – if – in – positioned – facing – store – result>
It will execute <command> at the location of <player or entity>, relative to <z> <y> <z>.
Syntax (usage): /fill <x> <y> <z> <dx> <dy> <dz> <block Name>[destroy – hollow – keep – outline – replace <Block Name>]
This command will fill between the 2 coordinates with <block Name>. In case replace is used for oldBlockHandling, the next parameter tells what block <block Name> should be substituted.
Syntax (usage): /gamemode <survival (0) – creative (1) – adventure (2) – spectator (3)> [player]
It can change the game mode of [player]’s to <survival – creative – adventure – spectator>.
If you want to know more commands for singleplayer in Minecraft, you are able to access some other sites such as Minecraft Wiki.