print

Create some text in the game world. The text is made of a type of block you choose at the position you want.

blocks.print(
    "HELLO",
    GRASS,
    pos(0, 0, 0),
    WEST
);

Parameters

  • text: the text to print in the world, like: “HELLO”
  • block: the block type that is used to create the text
  • position: position, or coordinates, where the text is printed in the world
  • direction: direction, the axis, along which the text is printed

Example

The following code writes “Hi!” in the sky near the player using gold blocks.

blocks.print(
    "Hi!",
    GOLD_BLOCK,
    pos(5, 2, 5),
    WEST
);