Used for accessing all available dimension types.
Private
Static
Retrieves a dimension type using a string-based identifier.
This function can be called in early-execution mode.
Retrieves an array of all dimension types.
import { DimensionTypes, world } from "@minecraft/server";const dimensions = DimensionTypes.getAll();for (const dimensionType of dimensions) { world.sendMessage(dimensionType.typeId);}// minecraft:overworld// minecraft:nether// minecraft:the_end Copy
import { DimensionTypes, world } from "@minecraft/server";const dimensions = DimensionTypes.getAll();for (const dimensionType of dimensions) { world.sendMessage(dimensionType.typeId);}// minecraft:overworld// minecraft:nether// minecraft:the_end
Used for accessing all available dimension types.