Edit

Share via


@minecraft/server Module

Contains many types related to manipulating a Minecraft world, including entities, blocks, dimensions, and more.

Changelog

Manifest Details

{
    "module_name": "@minecraft/server",
    "version": "2.1.0-beta"
}

This is version 2.x.x of this module, which is the latest as of version 1.21.90-beta.26 of Minecraft.

Available Versions

  • 2.1.0-beta

Prior Versions

The following API versions are from a major version that is documented here: @minecraft/server:

  • 1.19.0
  • 1.18.0
  • 1.17.0
  • 1.16.0
  • 1.15.0
  • 1.14.0
  • 1.13.0
  • 1.12.0
  • 1.11.0
  • 1.10.0
  • 1.9.0
  • 1.8.0
  • 1.7.0
  • 1.6.0
  • 1.5.0
  • 1.4.0
  • 1.3.0
  • 1.2.0
  • 1.1.0
  • 1.0.0

Enumerations

Type Aliases

Classes

Interfaces

Errors

Constants

HudElementsCount

static read-only HudElementsCount = 13;

Type: number

HudVisibilityCount

static read-only HudVisibilityCount = 2;

Type: number

MoonPhaseCount

static read-only MoonPhaseCount = 8;

Holds the number of MoonPhases

Type: number

TicksPerDay

static read-only TicksPerDay = 24000;

How many times the server ticks in one in-game day.

Type: number

Caution

This property is still in pre-release. Its signature may change or it may be removed in future releases.

TicksPerSecond

static read-only TicksPerSecond = 20;

How many times the server ticks per second of real time.

Type: number

Objects

system

static read-only system: System;

A class that provides system-level events and functions.

Type: System

world

static read-only world: World;

A class that wraps the state of a world - a set of dimensions and the environment of Minecraft.

Type: World