Skip to content

Utility command

XiaoColorful edited this page Mar 29, 2026 · 9 revisions

English

实用指令

/battleroyale utility [survivallobby/tosurvivallobby/lootconfig/profile/team] [id/save/load/remove/rebuild] [type/id/...] [.../overwrite]

生存模式大厅

/battleroyale utility [survivallobby/tosurvivallobby]

生存模式大厅信息

/battleroyale utility survivallobby

  • 查看大厅坐标
  • 查看大厅规模
  • 查看大厅是否启用无敌
  • 查看大厅是否启用治疗

传送至生存模式大厅

/battleroyale utility tosurvivallobby

生成配置文件

/battleroyale utility [lootconfig] [id] [type/toLootTable] [...]

生成物资刷新配置文件

/battleroyale utility lootconfig [id] [slot/block/chunk] [xyz] [repeat] [baseWeight] [chunkRadius] [autoReload]

需要权限等级3

新建物资刷新器配置文件

以单个物品槽为单位:

  • /battleroyale utility lootconfig ~ ~ ~ 0 slot 1 1 0 true
[
	{
		"lootId": 0,
		"name": "lootConfig-20260128_110543-slot",
		"color": "#FFFFFFAA",
		"entry": {
			"lootType": "repeat",
			"min": 1,
			"max": 1,
			"entry": {
				"lootType": "weight",
				"entries": [
					{
						"weight": 1.0,
						"entry": {
							"lootType": "item",
							"item": "minecraft:grass_block",
							"count": 64,
							"nbt": "{}"
						}
					},
					{
						"weight": 1.0,
						"entry": {
							// ...
						}
					},
					{
						"weight": 1.0,
						"entry": {
							// ...
						}
					}
					// ...
				]
			}
		}
	}
]

以单个方块/区块槽为单位:

  • /battleroyale utility lootconfig ~ ~ ~ 0 block 1 1 0 true
  • /battleroyale utility lootconfig ~ ~ ~ 0 chunk 1 1 0 true
[
	{
		"lootId": 0,
		"name": "lootConfig-20260128_110743-block",
		"color": "#FFFFFFAA",
		"entry": {
			"lootType": "repeat",
			"min": 1,
			"max": 1,
			"entry": {
				"lootType": "weight",
				"entries": [
					{
						"weight": 1.0,
						"entry": {
							"lootType": "multi",
							"entries": [
								{
									"lootType": "item",
									"item": "minecraft:grass_block",
									"count": 64,
									"nbt": "{}"
								},
								{
									"lootType": "item",
									"item": "minecraft:enchanted_golden_apple",
									"count": 64,
									"nbt": "{}"
								},
								{
									// ...
								}
							]
						}
					},
					{
						"weight": 1.0,
						"entry": {
							"lootType": "multi",
							"entries": [
								{
									// ...
								}
							]
						}
					}
				]
			}
		}
	}
]

转换成战利品表

/battleroyale utility [lootconfig] [id] toLootTable [fileName]

需要权限等级4

将刷新配置转换成战利品表,写入存档目录下单个文件 ./datapacks/battleroyale/data/battleroyale/loot_tables/{fileName}.json

  • 物资刷新配置几乎不能转化为战利品表,读取失败将导致无法进入存档(需要删除战利品表)
  • 请考虑使用背包刷新代替战利品表

预设配置

/battleroyale utility profile [save/load] [id] [overwrite]

保存配置预设

/battleroyale utility profile save [id] [overwrite]

将当前配置保存至 ./minecraft/config/battleroyale/server/profile

  • id:预设配置唯一id
  • overwrite:是否保存在当前配置下

应用预设配置

/battleroyale utility profile load [id]

自动切换至预设的配置文件及选用配置

  • id:预设配置唯一id

原版队伍

/battleroyale utility team [remove/rebuild] [...]

移除原版队伍

/battleroyale utility team remove [gameTeamOnly]

移除所有原版队伍,等价于批量执行 /team remove

  • gameTeamOnly:是否仅移除当前游戏队伍对应的原版队伍

/team remove 无法选中带空格的队伍名

重建原版队伍

/battleroyale utility team rebuild [formatString] [hideName] [forceRebuild]

重新为游戏队伍组建原版队伍:

  • formatString:同游戏配置vanillaTeamFormat
  • hideName:是否隐藏名称
  • forceRebuild:是否允许在游戏中重建
  • 该操作会先清空对应的原版队伍,并过滤掉不在指令执行维度内的游戏玩家

原版队伍不影响游戏队伍判定

English

/battleroyale utility [survivallobby/tosurvivallobby/lootconfig/profile/team] [id/save/load/remove/rebuild] [type/id/...] [.../overwrite]

Survival mode lobby

/battleroyale utility [survivallobby/tosurvivallobby]

Survival mode lobby info

/battleroyale utility survivallobby

  • Check lobby coordinates
  • Check lobby size
  • Check whether invulnerable is enabled in the lobby
  • Check whether heal is enabled in the lobby

Teleport to survival mode lobby

/battleroyale utility tosurvivallobby

Generate configuration file

/battleroyale utility [lootconfig] [id] [type] [...]

Generate loot spawner configuration

/battleroyale utility lootconfig [id] [slot/block/chunk] [xyz] [repeat] [baseWeight] [chunkRadius] [autoReload]

Require permission level 3

Create a new Loot spawner config:

By Single Item Slot:

  • /battleroyale utility lootconfig ~ ~ ~ 0 slot 1 1 0 true
  • /battleroyale utility lootconfig ~ ~ ~ 0 slot 1 1 0 true
[
	{
		"lootId": 0,
		"name": "lootConfig-20260128_110543-slot",
		"color": "#FFFFFFAA",
		"entry": {
			"lootType": "repeat",
			"min": 1,
			"max": 1,
			"entry": {
				"lootType": "weight",
				"entries": [
					{
						"weight": 1.0,
						"entry": {
							"lootType": "item",
							"item": "minecraft:grass_block",
							"count": 64,
							"nbt": "{}"
						}
					},
					{
						"weight": 1.0,
						"entry": {
							// ...
						}
					},
					{
						"weight": 1.0,
						"entry": {
							// ...
						}
					}
					// ...
				]
			}
		}
	}
]

By Block or Chunk:

  • /battleroyale utility lootconfig ~ ~ ~ 0 block 1 1 0 true
  • /battleroyale utility lootconfig ~ ~ ~ 0 chunk 1 1 0 true
[
	{
		"lootId": 0,
		"name": "lootConfig-20260128_110743-block",
		"color": "#FFFFFFAA",
		"entry": {
			"lootType": "repeat",
			"min": 1,
			"max": 1,
			"entry": {
				"lootType": "weight",
				"entries": [
					{
						"weight": 1.0,
						"entry": {
							"lootType": "multi",
							"entries": [
								{
									"lootType": "item",
									"item": "minecraft:grass_block",
									"count": 64,
									"nbt": "{}"
								},
								{
									"lootType": "item",
									"item": "minecraft:enchanted_golden_apple",
									"count": 64,
									"nbt": "{}"
								},
								{
									// ...
								}
							]
						}
					},
					{
						"weight": 1.0,
						"entry": {
							"lootType": "multi",
							"entries": [
								{
									// ...
								}
							]
						}
					}
				]
			}
		}
	}
]

Convert to loot table

/battleroyale utility [lootconfig] [id] toLootTable [fileName]

Require permission level 4

Convert the loot configuration into a loot table and write it to a single file at ./datapacks/battleroyale/data/battleroyale/loot_tables/{fileName}.json:

  • Loot configs can rarely be converted to loot tables; a reading failure will prevent entry into the save (requires deleting the loot table)
  • Consider using inventory loot instead of loot tables

Profile config

/battleroyale utility profile [save/load] [id] [overwrite]

Save config profile

/battleroyale utility profile save [id] [overwrite]

Save the current configuration to ./minecraft/config/battleroyale/server/profile

  • id: unique profile id
  • overwrite: Whether to overwrite the current configuration

Apply profile config

/battleroyale utility profile load [id]

Automatically switch to the preset configuration file and apply the selected configuration

  • id: unique profile id

Vanilla team

/battleroyale utility team [remove/rebuild] [...]

Remove vanilla team

/battleroyale utility team remove [gameTeamOnly]

Remove all vanilla teams, equivalent to executing /team remove in batches:

  • gameTeamOnly: Whether to only remove the vanilla teams corresponding to the current game teams.

/team remove cannot select team names containing spaces.

Rebuild vanilla team

/battleroyale utility team rebuild [formatString] [hideName] [forceRebuild]

Rebuild vanilla teams for game teams:

  • formatString: Same as vanillaTeamFormat in Game config.
  • hideName: Whether to hide names.
  • forceRebuild: Whether to allow rebuilding during the game.
  • This operation will first clear the corresponding vanilla teams and filter out game players who are not within the dimension where the command is executed.

Vanilla teams do not affect the determination of game teams.

🌐 Language / 语言


Clone this wiki locally