ScriptAPI v1.21.20の主な変更点
バージョンの更新
- @minecraft/server 1.14.0-beta 追加
- @minecraft/server 1.13.0 追加
PlayerCursorInventoryComponent 追加
プレイヤーがインベントリ内で選択中のアイテムを取得・削除できる
readonly item?: ItemStack
clear(): void
ItemStack Potion API
ポーションのItemStackを生成・情報を取得できるようになった
ItemStack.createPotion(opitons: PotionOptions): ItemStack
(static) 追加
効果時間の長い暗視のスプラッシュポーションのItemStackを作る例:
1const potion = ItemStack.createPotion({ 2 effect: 'NightVision', 3 liquid: 'Splash', 4 modifier: 'Long' 5});
- ItemPotionComponent 追加
effectType, liquidType, modifierTypeを取得できる
その他
World.isHardcore: boolean
追加Block.getMapColor(): RGBA
追加- EntityLeashableComponent 追加
leashTo(leashHolder: Entity)
追加 - エンティティに首紐を繋げられる
Entity.fallDistance
削除Entity.lifetimeState
削除- PlayerEmoteAfterEvent 追加
エモートしたプレイヤー,personaPieceId
を取得できる
Edit on Github