Script API - v1.20.60
    Preparing search index...

    The MinecraftEditor class is a namespace container for Editor functionality which does not have any player context.

    Index

    Properties

    log: Logger

    A global instance of the log output class object. This is not contextualized to any particular player, and any messages sent to this instance will be broadcast to all connected editor client sessions

    This property can throw when used.

    simulation: SimulationState

    Allows querying and modifying some properties of the simulation.

    Methods

    • Beta

      Parameters

      • extensionName: string

        Unique name of the editor extension being registered

      • activationFunction: (arg: ExtensionContext) => void

        A code closure which is called during the activation process and is responsible for setting up all of the extension internal settings and UI definitions

      • shutdownFunction: (arg: ExtensionContext) => void

        A code closure which is called during the deactivation process (when the player disconnects) and is responsible for cleaning up any settings or allocations

      • Optionaloptions: ExtensionOptionalParameters

        [ExtensionOptionalParameters] describes an optional object which contains a number of optional parameters which is used to register an extension with additional information

      Returns Extension

      This is an internal command which interfaces with the native C++ extension bindings and should not be used by creators. Using this command directly will not provide any of the additional functionality and wrappings that the TypeScript layer will provide. Creators should use the TypeScript binding registerEditorExtension instead

      This function can't be called in read-only mode.