This feedback post is a collection of small improvements to the Bedrock scripting API.
world.afterEvents.entityMount
Fires when an entity mounts another entity (boat, minecart, horse, etc)
import { world } from "@minecraft/server";
world.afterEvents.entityMount.subscribe((event) => {
if (!event.mountEntity.matches("boat")) return;
console.warn("Player entered boat!");
}, {type: 'player'});
world.afterEvents.entityDismount
Fires when an entity dismounts another entity.
import { world } from "@minecraft/server";
world.afterEvents.entityDismount.subscribe((event) => {
if (!event.mountEntity.matches("boat")) return;
console.warn("Player exited boat!");
}, {type: "player"});
ScoreboardObjective.tryGetScore()
Get a score from a ScoreboardIdentity, If it has no score it returns 0.
Player.resolveRawMessage(text: RawMessage|string): string
This function resolves raw text (including translations) using the player's locale language.
[Planned] - BlockCustomComponent.onNeighborUpdate
This function will be called when a block has been placed/updated next to this block.
[1.6.0] world.seed: number
Returns the world seed.
[2.6.0] - ItemDurabilityComponent.unbreakable
Makes the tool unbreakable.
[2.3.0] Dimension.getBiome(location): string|undefined
Returns the biome id from a block position.
Please sign in to leave a comment.
1 Comments