Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Minecraft:Commands/datapack

From SAS Gaming Wiki
Revision as of 20:09, 9 April 2026 by SyncBot (talk | contribs) (Fix template calls: add MC/ prefix)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Template:Hatnote Script error: No such module "Exclusive". Template:Infobox command

Controls the loading/unloading of data packs.

Note that feature flags can be enabled through data pack only when creating the world. Data packs requiring a feature flag that is not enabled cannot be loaded by this command.

If a built-in datapack in the path of datapacks in the vanilla datapack is enabled during world creating, it cannot be disabled by this command.

Syntax

datapack disable <name>
Disable the specified pack.
datapack enable <name>
Load the specified pack.
datapack enable <name> (first|last)
Load this pack before (lowest priority) or after (highest priority) all others (lowest or highest priority).
datapack enable <name> (before|after) <existing>
Load this pack just before (lower priority) or after (higher priority) an existing pack.
datapack list [available|enabled]
List all data packs, or list only the available/enabled ones. Hovering over the data packs in the chat output shows their description defined in their pack.mcmeta.
datapack create <id> <description>
Creates new empty directory data pack for current world.

Arguments

<name>: string

Specifies the name of the data pack.
{{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|string}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}

<existing>: string

Specifies the name of an existing enabled data pack.
{{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|string}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}

<id>: string

Created pack name, must be a valid directory name.
{{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|string}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}

<description>: string

text component to be placed in description in pack.mcmeta.
{{#vardefine:onlyje|}}{{#vardefine:onlybe| Template:IN,}}{{#vardefine:je-arg|string}}{{#vardefine:be-arg|}}Template:Error{{#vardefine:onlyje|}}{{#vardefine:onlybe|}}{{#vardefine:je-arg|}}{{#vardefine:be-arg|}}

Result

Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table Template:Result table

Output

{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}

{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On fail}}{{#vardefine:output1-{{#var:output-table-lines}}|0}}{{#vardefine:output2-{{#var:output-table-lines}}|0}}{{#vardefine:output3-{{#var:output-table-lines}}|0}}{{#vardefine:command-row-{{#var:commands-num}}|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-editions-num|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-edition-{{#var:output-editions-num}}|je}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|1}} {{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:situation-{{#var:output-table-lines}}|On success}}{{#vardefine:output1-{{#var:output-table-lines}}|1}}{{#vardefine:output2-{{#var:output-table-lines}}|1}}{{#vardefine:output3-{{#var:output-table-lines}}|The number of packs that are loaded after executing.}}{{#vardefine:commands-num|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:command-{{#var:commands-num}}|/datapack enable ...
/datapack disable ...
}}{{#vardefine:command-row-{{#var:commands-num}}|1}}{{#vardefine:output-edition-row-{{#var:output-editions-num}}|Expression error: Unrecognized punctuation character "{".}} Template:Output table

{{#vardefine:output-table-lines|Expression error: Unrecognized punctuation character "{".}}{{#vardefine:output-table-lines|-2}}{{#vardefine:output-table-lines-now|}}{{#vardefine:command-num-now|}}{{#vardefine:command-line-now|}}{{#vardefine:commands-num|}}{{#vardefine:output-edition-num-now|}}{{#vardefine:output-edition-line-now|}}{{#vardefine:output-editions-num|}}{{#vardefine:je-outputs-dis|}}

History

Template:HistoryTable

References

<references/>

Navigation

All editions
Removed
Template:El only
Debug
Removed
Template:Els only
Template:El only
Removed
Template:El only
Removed
Template:Els only
Removed
Joke
Related

de:Befehl/datapack es:Comandos/datapack ja:コマンド/datapack pt:Comandos/datapack ru:Команды консоли/datapack th:คำสั่ง/datapack zh:命令/datapack