Beta
@minecraft/common (Optional in Manifest Details)
{
"module_name": "@minecraft/common",
"version": "1.0.0"
}
@minecraft/server (Required in Manifest Details)
{
"module_name": "@minecraft/server",
"version": "2.1.0-beta"
}
Install type definition for @minecraft/server-editor
module using npm:
npm i @minecraft/server-editor@0.1.0-beta.1.21.90-preview.25
The types of actions that are supported. This type corresponds to the expected arguments passed by the onExecute handler of an action.
The possible operation types supported by BlockTable property item.
The possible variants of a bool.
The possible variants of a Button property item.
The possible variants of a color picker.
The possible data types supported by ComboBox property item.
Execution state of the continuous action
Predefined action bar items
Core brush shape types
Predefined top level menus for core editor
An enumeration used by the 3D block cursor Cursor
Describes how the cursor targets a point on the screen.
Global editor input contexts
Enumeration representing the different modes Editor can be in.
Enumeration representing identifiers for graphics settings properties.
Supported image types.
Input modifier flags to create chorded bindings
Keyboard key
Determines how key binding should be processed to fire actions
Alignment options for UI elements
Layout directions for property panes.
Mouse device action categories
Detailed mouse device actions
Input event information about mouse actions
The possible variants of a Number property item.
The possible variants of a ProgressIndicator property item.
Type of item that can be added to the property pane
Define the visibility of the status bar item If the tool
does not have an ISimpleToolPropertyPane
component, then
this option is ignored
Position for items on the status bar
A cache for bedrock event subscriptions. Stores off a subscription by event key, and upon teardown unregisters all subscriptions.
Validates observable objects that support string list as BlockType
Validates observable objects that support string as BlockType
Base for creating new brush shapes
A ClipboardItem is a handle to an object which represents a set of blocks in a contained bounding area (most likely copied from the world)
The ClipboardManager (accessible from the ExtensionContext) is responsible for the management of all ClipboardItem objects, and provides the user the ability to create new ClipboardItem objects for use within an extension.
Base for creating new brush shapes
Base for creating new brush shapes
The 3D block cursor is controlled through this read only object and provides the Editor some control over the input methods, display properties and positioning of the 3D block cursor within the world. The 3D block cursor is a native object which is constantly calculating a screen/mouse -> world raycast, and recording the resultant block collision position and facing direction. Depending on the properties of the cursor state, this is not always true – the cursor can also be manually manipulated by keyboard input and moved around independently of mouse movement; when the mouse is moved, the block cursor will return to the mouse/world ray intersection point. The cursor can also be set to either block or face mode; block mode represents the block the mouse is pointing at, and face mode represents the adjacent block that the mouse is pointing at (i.e. the block attached to the face of the intersection point). In practical use, each tool when activated grabs the current cursor state object and stores it. The active tool then sets the current state to represent the functionality of the tool (color, input mode, etc). When the tool loses focus, it restores the cursor state using the stored state object that was grabbed during activation. The 3D block cursor can also be used to query the current block at which the mouse is pointing (or the current block to which the cursor has been manually moved by the user)
Base for creating new brush shapes
Base for creating new brush shapes
Validates observable objects that support string as EntityType
Editor Extensions are the basis for all player specific, editor specific functionality within the game. Almost all editor functionality is exported and available within the context of an ExtensionContext When the script manager initializes during level loading, the scripts are loaded from the behavior packs and executed. As part of the global execution context, the scripts are free to register any number of extensions. An Editor Extension is defined a name, an activation function and a shutdown function.
The extension context is a native (C++) object created for each registered Editor Extension, when a player connection is established with the server. A registered extension activation or deactivation closure is accompanied by an [ExtensionContext] object, which provides a player specific, editor extension specific context. The Extension Context is the main interface to all the bound Editor Services. As more player services are added to the editor, they will be exposed through this object
Contains a set of events that are available across the scope of the ExtensionContext.
Settings category that manages GraphicsSettingsProperty configurations.
The logger class is a utility class which allows editor extensions to communicate with the player from the server to the client log window. The logger class presents 4 different output channels which can be used to send information to the client/player, depending on the context of the information.
The MinecraftEditor class is a namespace container for Editor functionality which does not have any player context.
Contains information related to changes in player editor mode.
Manages callbacks that are connected to when a player editor mode changes.
Validates min/max limits of observable objects that support number
Used for validating an observable value before it gets set
Base for creating new brush shapes
Base type for BlockVolumes.
The SelectionManager (accessible from the ExtensionContext) is responsible for the management of all @minecraft/server-editor.Selection objects, and provides the user the ability to create new @minecraft/server-editor.Selection objects for use within an extension.
The SettingsManager (accessible from the ExtensionContext) is responsible for the management all player settings.
A simple class wrapper to inherit in your tool which
contains the initialization and storage of the simple tool
component utility. See one of the Simple
samples to see
how to use this class and the wrapper framework
Responsible for querying and modifying various properties of the simulation.
Base for creating new brush shapes
The Transaction Manager is responsible for tracking and managing all of the registered transaction operations which represent creator changes in the world. Transaction Manager is the basis of the UNDO and REDO operations, and allows a creator to store the changes made to the world and the state of the world BEFORE those changes were applied, making it possible to UNDO those changes and restore the world state. The transactions are stored as a stack, and can be undone in stack order to restore the world to it's original state
A strongly typed transaction handle to enforce type safety
when adding user defined transactions.
This transaction
handle becomes the context for adding the transaction to the
transaction manager.
You can obtain one of these handles
by calling registerUserDefinedTransactionHandler
Validates min/max limits of observable objects that support Vector3
Binds actions to the client and manages their lifetime. Action managers are managed on a per player basis since client side UI is per player.
Represents a UI session for a given player
Interface used to specify the options when a clipboard item is being written to the world
The CursorProperties interface is used to describe the properties of the Editor 3D block cursor construct. The 3D block cursor can be queried to retrieve the current properties, and the same property class can be used to set the current properties of the cursor. This interface is generally used at the activation stage of the active tool to set up the color, visibility and input properties of the 3D block cursor
An event that can be subscribed to. You can use the token, returned from the subscribe method, to clean up handlers.
An interface which defines the set of optional parameters
which can be used when calling the registerEditorExtension
function
Manager for IActionBarItem objects.
Registered item handle in the Action Bar collection.
Properties required to create an Action Bar item.
A property item which supports block list properties
Optional properties for Bool property item
Block Table Entry info for block table property item
A property item which supports Block Table properties
Properties of block table item
A property item which supports boolean properties
Optional properties for Bool property item
A property item pane which supports multiple buttons
Optional properties for Button Pane property item
A property item which supports Button properties
Optional properties for Button property item
A property item which supports Color Picker properties
Optional properties for Color Picker property item
A property item which supports Color Timeline properties
Properties of color timeline property item entry
Optional properties for Color Timeline property item
A property item which supports Combo Box properties
Optional properties for ComboBox property item
A property item which supports data entries displayed in a table
Properties of data table property item menu entry
Properties of data table item
Simple abstraction for disposable objects.
A property item which supports Dropdown properties
Properties of dropdown property item menu entry
Optional properties for Dropdown property item
Returned from an event subscription. Provides functionality for cleaning up listeners
A property item which supports Image properties
Optional properties for Image property item
A property item which supports Link properties
Optional properties for Link property item
Manager and container for IMenu objects
Properties required to create a Menu
A sub pane for modal control elements.
A modal overlay pane is displayed over a root pane.
The options to create a modal overlay pane.
A property item which supports Number properties
Optional properties for Number property item
A property item which supports Number Timeline properties
Properties of the Number timeline property item entry
Optional properties for Number Timeline property item
Represents a stateful value that can be observed by different objects.
Pane represents a container for UI components.
Log helper interface for Player.
A property item which supports ProgressIndicator properties
Optional properties for progress indicator property item
Common base for all property items
Common optional properties for property items
Property pane present dynamic content. It can be associated with an object and presented with different kind of controls.
Common optional properties used for constructing a property pane.
Key binding that is registered to an input context
Optional parameter definition for RegisterEditorExtension function Allows the extension registrar to specify optional textual description and notes which would be visible through the extension manager
A root pane that can store property items.
Represents the data to display an action button on a root property pane header.
The options to create a root pane.
The simple tool wrapper will create, bind and manage the lifecycle of all the desired components. The wrapper is designed to obfuscate and simplify the process of creating a simple editor tool so that a creator can get on with the job of just creating the tool functionality without getting mired in the irrelevant details of component lifecycle and visibility management. The wrapper will also attempt to codify particular implementation patterns and requirements that are common to all editor tools, and enforce them in a consistent way. It should also go some way to insulating the creator from underlying system and implementation changes as the editor evolves.
Define a key binding for the simple tool activation
A set of options which define the basic properties of a simple tool, and the optional components that are desired.
The Simple Tool pane component represents the main window
(or sub-window) for an editor tool. The pane components are
stored as a hierarchy (see the ISimpleToolPaneOptions
interface for more details) and are the main containers for
all of the UI controls used by the editor tool. Panes are
optional (a tool doesn't necessarily need to have a pane),
but if a pane is present, then it is one of two type - Modal
Pane (appears on the left side of the display; visibility is
tied to the ISimpleToolRail
component) (Note that there
can be only one modal pane visible at a time) - Global Pane
(appears on the right side of the display; visibility is up
to the creator/user)
A set of options which define the basic properties of a
window pane (or sub-pane) for a simple tool. This pane can
be a top level pane, or a child pane of the top level pane,
and is the content container for all of the UI controls used
by the editor tool. Each pane is uniquely identified by the
id
property, and has a number of optional function
closures which are called at various points in the pane's
lifecycle. Note that instead of having a single onFinalize
function, panes implement a pair of onBeginFinalize
and
onEndFinalize
functions. This is to allow for the pane to
be partially constructed BEFORE any child panes are
constructed. Once all child panes have been fully finalized,
then the onEndFinalize
function is called to allow the
pane to finalize itself.
The tool rail component allows the tool to register an icon
and button (and dynamic tooltip) in the tool rail on the
left side of the display. Adding a tool rail component to a
tool will cause the tool to be considered a modal tool
,
and only one single modal tool can be active at any one
time. Modal tools are generally tools which take focus and
control of the cursor (e.g. selection, clipboards, entity
selection, etc) Global tools (tools which do not have a tool
rail) are generally things like property pages, settings,
etc - things that do not require an active cursor or
gameplay interaction
A set of options which define the basic properties of a status bar item for a simple tool.
Manager and container for IStatusBarItem objects
Properties required to create a status bar item
A property item which supports String properties
Optional properties for String property item
A property item which supports Sub Pane properties
Optional properties for Sub Pane property item
A property item which supports Text properties
Optional properties for Text property item
A property item which supports toggle button properties
Properties of toggle group property item list entry
Optional properties for Toggle Group property item
A property item which supports Vector3 properties
Optional properties for Vector3 property item
A properties class for the global instance of the logger object. While the logger object is available through the ExtensionContext - using the global instance allows the creator to use this properties class to perform direct server->client messaging and broadcasts.
Parameters for creating a modal tool in the tool container
Full set of all possible raw actions
All actions have a unique identifier. Identifiers are globally unique and often GUIDs
Callback type when an extension instance is activated for a given player. It is expected to return an array of disposables that will automatically be cleaned up on shutdown.
All possible button item action types
An action that continues to execute after activation
A generic handler for an event sink.
Defines type information for graphics settings properties.
Animation properties for a horizontally laid out sprite sheet image
Type that can be an observable or a value.
The IPlayerUISession represents the editor user interface for a given player and given extension. Extensions registered with Minecraft are instantiated for each player which joins a server, and this interface provides the set of functionality needed to create and modify the editor UI for that player. The associated Editor Context for this session object is also player specific. From a given IPlayerUISession object, there is no way to interact with the UI of another player, that must be done from global extension scope registration and/or data sharing independent of the UI object.
Keyboard binding properties.
Additional information about key binding.
Represents a localized string or an object with a localized string and optional properties
Modal tool lifecycle event payload
Input modifier states for mouse actions
Mouse properties that provide additional information from client event handling
An action which returns the ray corresponding to a vector from the users mouse click in the viewport.
An action which needs no additional client side arguments on execute
Callback to execute when a visibility of a property pane is updated.
Ray representing a direction from a set location. This location typically corresponds to the location of a mouse click performed on the client.
A registered action is an action that has been registered with the action manager system and has a unique ID representing the action now. An action must be registered before it can be used in other systems.
Callback type when an extension instance is shutdown for a given player. Used for performing any final work or clean up that can't be handled automatically via Disposables.
An action which returns the activation state.
Full set of all possible keyboard actions
Full set of all possible mouse actions
Content properties to display interactive tooltips
Possible tooltip description items
Tooltip link description
Manifest Details