跳到主要内容

Minecraft Beta & Preview - 1.20.0.22

Add-Ons and Script Engine

  • Pumpkin blocks use the string type state "minecraft:cardinal_direction" instead of the int type "direction" state

Commands

  • Has item command selector now correctly detects whether or not an actor has a filled Map or Firework Star in their inventory
  • The "inputpermission" command now has a description displayed in the command dialogue preview

Bedrock Editor

  • Fixed a bug where the default command permission level of the client differed from what was displayed in a multiplayer session
  • Tool mode movement will now use the vanilla keyboard controls instead of hardcoded W/A/S/D/Space/Shift keys. Movement bindings can now be customized from the settings menu, but some keys might not be available if they are being used by other editor actions

Items

  • Custom items with 'minecraft:record' show the correct sound description in hover text and on playing in a Jukebox

实验性特性

Add-Ons

  • Changed "minecraft:cardinal_direction" and "minecraft:facing_direction" states from int to string type.
    • "minecraft:cardinal_direction" has four values ["north", "south", "east", "west"]
    • "minecraft:facing_direction" has six values ["down", "up", "north", "south", "east", "west"]
  • Added a new experimental Cameras toggle to allow for custom camera perspectives
  • Removed "knockback_resistance" item component

Script API

  • New APIs moved from beta to stable @minecraft/server 1.2.0:
    • Moving _applyDamage(amount: number, options?: EntityApplyDamageByProjectileOptions | EntityApplyDamageOptions): boolean_to 2.0
    • Moving _kill(): boolean_to 2.0
    • Moving _EntityApplyDamageOptions_to 2.0
    • Moving _EntityApplyDamageByProjectileOptions_to 2.0
    • Moving _EntityDamageCause_to 2.0
    • Moving _addTag(tag: string)_to 2.0
    • Moving _removeTag(tag: string)_to 2.0
    • Moving _hasTag(tag: string)_to 2.0
    • Moving _getTags()_to 2.0
    • Moved _Container_and BlockInventoryComponent and EntityInventoryComponent to 2.0
    • Moved Music APIs from beta to stable
    • Moved Sound APIs from beta to stable
    • Moved ModalFormDataMessageFormData, and _ActionFormData_to 0.0
    • Fixed bug in response of _MessageFormResponse_where selection was inverted from which button was selected. button1 now refers to the left button and results in a selection of 0 and button2 now refers to the right button and results in a selection of 1
    • Moved _ItemStack_constructor and getter APIs to 2.0
    • Moved EntityItemComponentItemComponent, _ItemType_and ItemLockMode to 2.0
    • Moving _applyImpulse(vector: Vector3): void_to 2.0
    • Moving _applyKnockback(directionX: number, directionZ: number, horizontalStrength: number, verticalStrength: number): void_to 2.0
    • Moving _clearVelocity(): void_to 2.0
    • Moved _runCommand_from beta to 2.0
  • Enchantments
    • Removed MinecraftEnchantmentTypes class. Use MinecraftEnchantmentTypes from @minecraft/vanilla-data module for minecraft version specific information.
    • Added support for "strings" in all Enchantment methods for specifying the enchantment type
  • _source_on ExplosionBeforeEvent is now an optional property because explosions may not have a source
  • Tameable Component
    • Removed unimplemented _tameEvent_from TameableComponent
  • Updated API to better handle operations outside of loaded and ticking areas
  • PositionInUnloadedChunkError: Exception thrown when trying to interact with a Block object that isn't in a loaded and ticking chunk anymore
  • PositionOutOfWorldBoundariesError: Exception thrown when trying to interact with a position outside of dimension height range
  • Dimension
    • getBlock now returns an optional Block to reflect it might return 'undefined' if asking for a block at an unloaded chunk
  • Signs
    • Added optional _SignSide_parameter to functions setTextgetTextgetRawTextsetTextDyeColor, and getTextDyeColor on BlockSignComponent to support getting and setting text and colors on both sides of signs.
    • Added _isWaxed_property to BlockSignComponent indicating whether players can edit the sign or not.
    • Added _setWaxed_method to BlockSignComponent to block players from editing the sign.
  • _runCommand_and runCommandAsync on Dimension and Entity can now fail with a CommandError
    • _runCommand_can throw a CommandError exception
    • _runCommandAsync_will pass a CommandError into the reject handler

Commands

  • Added /camera command as part of the experimental Cameras toggle
    • This command can switch to custom camera perspectives or fade the screen
  • Use /help camera to get a full list of options