<本站文本内容除另有声明外,转载时均必须注明出处。(详情…本站文本内容除另有声明外,转载时均必须注明出处。(详情…中文Minecraft Wiki是完全公开的。请勇于扩充与修正内容!中文Minecraft Wiki是完全公开的。请勇于扩充与修正内容!Minecraft中文Wiki微博正在更新!或许有兴趣去看看Minecraft中文Wiki微博正在更新!或许有兴趣去看看想与其他用户进行编辑上的沟通?社区专页正是为此创建的。想与其他用户进行编辑上的沟通?社区专页正是为此创建的。翻译或创建页面之前,不妨看看译名标准化Wiki条例页面。翻译或创建页面之前,不妨看看译名标准化Wiki条例页面。需要管理员的协助?在管理员告示板留言也许可以帮到您。需要管理员的协助?在管理员告示板留言也许可以帮到您。>

维度

来自Minecraft Wiki
跳转至: 导航搜索
Information icon.svg
此特性为Java版独有。
Grass Block JE6 BE5.png
本页面包含会在下一个更新中出现的内容。

这些特性已经在开发版本中出现,但包含这些特性的正式更新尚未发布。

Iron Pickaxe JE2 BE2.png
该页面的编辑正在进行中。

请帮助我们扩充或改进这篇文章。

Ic translate.svg
此条目的(部分)内容需要翻译。

你可以帮助我们来翻译此条目,但请勿使用机器翻译

维度(Dimension)是位于数据包中用于定义世界的新维度的JSON文件。这些维度可以通过运行/execute in <维度> run teleport <坐标>到达。

用途[编辑 | 编辑源代码]

要使用维度,JSON文件必须首先放置在<世界名称>/datapacks/<数据包名称>/data/minecraft/dimension/<命名空间>下。<数据包名称>文件夹内也应当有一个pack.mcmeta文件。

维度语法[编辑 | 编辑源代码]

不像其他数据包内容那样,维度只在minecraft命名空间内工作,并且需要一个子文件夹作为“命名空间”。例如,custom:test会调用data/minecraft/dimension/custom/test.json

  • 根标签。
    •  type维度类型的命名空间ID。也可以是一个硬编码的维度类型,但只能使用一次。自定义的维度可以重复使用。
    •  generator:维度的生成设置。
      •  type:生成器的ID。前缀是minecraft:,之后是flatnoisedebug
      • 其他组件(见下)

生成器类型[编辑 | 编辑源代码]

 generator标签的格式取决于生成器的ID( type)。

当生成器ID类型是minecraft:noise时:

  •  generator: 维度的生成设置。
    •  type:生成器的ID,此时是noise
    •  seed:用于生成该维度的种子。大部分情况下,这个值与世界种子一致,但是可以与其不一样,不一样的时候该维度就会使用这个值作为种子生成,而不是世界种子。 ‌[需要测试]
    •  settings:The shape of the terrain.可以设为一个字符串以使用预设,或者可以设为一个包括自定义选项列表的复合标签。The string values the settings object can be set to to load default settings include minecraft:overworld for normal Overworld generation, minecraft:amplified for 放大化 Overworld generation, minecraft:nether for regular Nether generation, minecraft:caves for Nether-like generation but with Overworld 地形特征, minecraft:end to generate the main End island, and minecraft:floating_islands for End 浮岛 generation.
      •  bedrock_roof_position: The distance from the world height for the top coordinate of the bedrock roof, if out of bounds (0-255) the roof will not appear. e.g. setting this to 32 will put the top of the roof at y=224. If the bedrock roof is low enough, natural terrain will still generate above it. ‌[需要测试]
      •  bedrock_floor_position: The y coordinate of the bedrock floor, similar to bedrock_roof_position – setting both floor and roof to 255 will generate a single layer of flat bedrock for each of them. ‌[需要测试]
      •  sea_level: The sea level in this dimension between 0 and 255
      •  disable_mob_generation: Can be true or false. ‌[需要测试]
      •  structures:结构设置。
        •  structures: List of structures to use in this dimension
          •  <namespaced id>: The key for this field should be the namespaced ID of a structure, a list is available at Java版数据值 §结构. If structures are not listed, the default structures from the dimension specified in biome_source > type will spawn at an extremely increased rate in the biomes they naturally spawn in. All structures must be listed for stable generation of non flat world types.
            •  spacing (number): Maximum distance between two structures of this type in chunks[注 1].
            •  separation (number): Minimum distance between two structures of this type in chunks; must be less than spacing.
            •  salt (integer):‌[需要测试] A number that assists in randomization; see salt (cryptography).
      •  noise: Parameters for world generation.
        •  top_slide: Settings for the curve at the top of the world.
          •  target (integer): The value of the curve. Negative values will round off the top of the hills in the affected area, positive values will create a roof. The higher the value is, the larger the effect will be.
          •  size (integer): Defines the size of the affected area from the top of the world. size is calculated using the formula size = <height in blocks> * 0.25 / size_vertical.
          •  offset (integer): Moves the affected area from the top of the world. offset uses the same formula as size so offset = <height in blocks> * 0.25 / size_vertical. For top_slide, positive values move the area down and negative values bring it up.
        •  bottom_slide: Settings for the curve at the bottom of the world.
          •  target (integer): The value of the curve. Negative values will remove the floor and round off the bottom of the islands, positive values will make a floor. The higher the value is, the larger the effect will be.
          •  size (integer): Defines the size of the affected area from the bottom of the world. Uses the same formula as in top_slide.
          •  offset (integer): Moves the affected area from the bottom of the world. Uses the same formula as in top_slide. For bottom_slide, positive values move the area up and negative values bring it down.
        •  sampling: ‌[需要测试]
          •  xz_scale (double): Scales the X and Z axis of the noise. Higher values results in more intricate horizontal shapes.
          •  xz_factor (double): Smoothes the noise on the horizontal axis.
          •  y_scale (double): Scales the Y axis of the noise. Higher values will result in more intricate vertical shapes.
          •  y_factor (double): Smoothes the noise on the vertical axis.
        •  size_vertical (integer): Changes the Y scale of the landmass. Values between 1 and 15 gradually increase the hill height, above 20 are all above the normal sea level of 63, and higher than 32 give normal land levels of 100+.‌[需要测试]
        •  size_horizontal (integer): Changes the X/Z scale of the landmass, but not the biomes.‌[需要测试]
        •  height (integer): Changes the max height of generated terrain by squashing the world. For example, with height=128, the ground is set to Y=32. this does not affect sea level.‌[需要测试]
        •  density_factor (double):‌[需要测试]
        •  density_offset (double; values between -1 and 1): Affects the average land level (not sea level).‌[需要测试]
        •  random_density_offset (boolean; optional):‌[需要测试]
        •  simplex_surface_noise (boolean):‌[需要测试]
        •  island_noise_override (boolean; optional): Causes the world to generate like 末地 with a big island in the center and smaller ones around.
        •  amplified (boolean; optional): Toggles between amplified and normal terrain generation. Can be used alongside large biomes in `vanilla_layered` types, and in any dimension (Nether, End, and custom).
      •  default_block: The block that appears below the top blocks of the world; see Java版数据值 §方块
        •  Name: ID of the block
        •  Properties: Block states
          •  state (string): A block state key and its value.
      •  default_fluid: The block used for seas and lakes; see Java版数据值 §流体.
        •  Name (string): ID of the block
        •  Properties: Block states
          •  state (string): A block state key and its value.
    •  biome_source: Settings dictating which biomes and biome shapes.
      •  seed (integer): The seed used for biome generation. In most cases, this is exactly the same as the dimension seed (and by extension the world seed), but can be different and the biome generation for this dimension will be based upon this seed and not the dimension seed.‌[需要测试]
      •  type (string): The type of biome generation. Arguments lie in the biome_source compound. Some possible values for type include minecraft:vanilla_layered 和 minecraft:fixed 和 minecraft:checkerboard 和 minecraft:multi_noise 和 minecraft:the_end.‌[需要更多信息]
        • vanilla_layered: Default and large biome generation used in the overworld.
          •  large_biomes (Boolean): Whether the biomes are large. True for biomes generation in the "Large Biomes" world type.
          •  legacy_biome_init_layer (Boolean): Whether the world was default_1_1.‌[需要测试]
        • multi_noise: 3D biome generation used in the nether.‌[需要测试]
          •  preset (string): A preset of the set of biomes to be used, mutually exclusive with  biomes[需要测试] the only valid that's currently supported is minecraft:nether.
          •  biomes: A list of biomes, including their likelihood.
        • the_end: Biome generation used in the end with biome minecraft:the_end in the center and other end biomes around.‌[需要测试]
        • fixed: a single biome.
          •  biome: The single biome to generate.
        • checkerboard: A biome generation in which biomes are square (or close to square) and repeat along the diagonals.
          •  biomes: A list of biomes that repeat along the diagonals (can be more than 3).
          •  scale: Determines the size of the squares on an exponential scale.

当生成器ID类型是minecraft:flat(用于生成超平坦世界地形)时:

  •  generator:维度的生成设置。
    •  type:生成器的ID,此时是flat
    •  settings: Superflat settings.
      •  layers: Layer settings.
        • : A superflat layer. This list is interpreted from top to bottom.
          •  height: The number of blocks in the layer.
          •  block: The block the layer is made of.
      •  biome: the single biome of the world
      •  structures: Structure settings
        •  <structure name>: A structure generated with presets before 20w21a. The compound contains the parameters set in the preset. Does not change anything about structure generation, but is set because of the old preset.
        •  structures: List of structures to use in this dimension
          •  <namespaced id>: The key for this field should be the namespaced ID of a structure, a list is available at Java版数据值 §结构. [note: contrary to that of non-flat worlds, if a structure is not listed, it will not generate at all]
            •  spacing: unsure of purpose. when tested on end cities, anything 10 or lower generated 0 structures. (number) ‌[需要测试]
            •  separation: Spacing between structures, unit? (probably chunks), min, max or average? (number) ‌[需要测试]
            •  salt:‌[需要测试] A number that assists in randomization; see salt (cryptography).

当生成器ID类型是minecraft:debug时(用于生成调试世界时):‌[需要更多信息]

  •  generator:维度的生成设置。
    •  type:生成器的ID,此时是debug

维度类型语法[编辑 | 编辑源代码]

不像其他数据包内容那样,维度类型只在minecraft命名空间内工作,并且需要一个子文件夹作为“命名空间”。例如,custom:test会调用data/minecraft/dimension_type/custom/test.json

  • 根标签
    •  ultrawarm (Boolean): Can be true or false. Whether the dimensions behaves like the nether (water evaporates and sponges dry) or not. Also causes lava to spread thinner.‌[需要测试]
    •  natural (Boolean): Can be true or false.‌[需要测试] When false, compasses will spin randomly. When true, nether portals can spawn zombified piglins.
    •  shrunk (Boolean): Can be true or false. Determines whether the dimension is treated as eight meters per block like in the Nether.‌[需要测试]
    •  has_skylight (Boolean): Can be true or false. Whether the dimension has skylight access or not.
    •  has_ceiling (Boolean): Can be true or false. Whether the dimension has a bedrock ceiling or not. When true, causes lava to spread faster.
    •  ambient_light (float): How much light the dimension has, default is 0.5 in the demo file (for upper and lower bounds as well as precise effect‌[需要测试]).
    •  fixed_time (Boolean or integer; optional): Can be false or any integer from 0 to 24000. If this is set to a number, the time of the day will always be the specified value. However, in at least some worlds,‌[需要测试] false is interpreted as 0, giving constant sunrise. To ensure a normal time cycle, leave the attribute undefined (i.e, do not include it).
    •  biome_zoomer (string; optional): Can be FuzzyOffsetConstantColumnBiomeZoomer (used in the Overworld) or FuzzyOffsetBiomeZoomer (used in the nether and the end).‌[需要测试]
    •  ender_dragon (Boolean; optional): Can be true or false. Whether the dimension has an ender dragon boss.

默认[编辑 | 编辑源代码]

这些是原版中的3个维度使用的设置。

主世界
  • fixed_time: N/A
  • has_skylight: False
  • has_ceiling: False
  • ultrawarm: False
  • natural: True
  • shrunk: False
  • ender_dragon: False
  • biome_zoomer: FuzzyOffsetConstantColumnBiomeZoomer
  • ambient_light: -0.5
下界
  • fixed_time: 18000
  • has_skylight: False
  • has_ceiling: True
  • ultrawarm: True
  • natural: False
  • shrunk: True
  • ender_dragon: False
  • biome_zoomer: FuzzyOffsetBiomeZoomer
  • ambient_light: 0.1
末路之地
  • fixed_time: 6000
  • has_skylight: False
  • has_ceiling: False
  • ultrawarm: False
  • natural: False
  • shrunk: False
  • ender_dragon: True
  • biome_zoomer: FuzzyOffsetBiomeZoomer
  • ambient_light: 0.0

历史[编辑 | 编辑源代码]

Java版(即将到来)
1.16pre1数据包中加入了dimensiondimension_type

漏洞[编辑 | 编辑源代码]

关于“Dimension”或“Dimension type”的漏洞由漏洞追踪器维护,请在此汇报漏洞。

参考[编辑 | 编辑源代码]

  1. Setting this to a number does not mean at least one structure will be generated every so often, only that the game will attempt to generate one; biomes or terrain could lead to the structure not being generated