@minecraft/server-editor 0.1.0-beta.1.21.50-preview.26 → 0.1.0-beta.1.21.50-preview.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.d.ts +80 -17
  2. package/package.json +2 -2
package/index.d.ts CHANGED
@@ -31,7 +31,14 @@ export declare enum ActionTypes {
31
31
  NoArgsAction = 'NoArgsAction',
32
32
  }
33
33
 
34
+ export enum Axis {
35
+ X = 1,
36
+ Y = 2,
37
+ Z = 4,
38
+ }
39
+
34
40
  export enum BlockMaskListType {
41
+ Disabled = 'Disabled',
35
42
  Mask = 'Mask',
36
43
  Replace = 'Replace',
37
44
  }
@@ -228,6 +235,7 @@ export enum GamePublishSetting {
228
235
  */
229
236
  export enum GraphicsSettingsProperty {
230
237
  ShowChunkBoundaries = 'ShowChunkBoundaries',
238
+ ShowCompass = 'ShowCompass',
231
239
  /**
232
240
  * @remarks
233
241
  * Manages rendering of invisible blocks (e.g., barrier, light,
@@ -898,12 +906,13 @@ export enum PaintCompletionState {
898
906
  export enum PaintMode {
899
907
  BlockPaint = 0,
900
908
  FreehandSelect = 1,
909
+ Smooth = 2,
901
910
  }
902
911
 
903
912
  export enum Plane {
904
- XY = 0,
905
- XZ = 1,
906
- YZ = 2,
913
+ XY = 1,
914
+ XZ = 2,
915
+ YZ = 4,
907
916
  }
908
917
 
909
918
  export enum PlayerPermissionLevel {
@@ -973,6 +982,10 @@ export declare enum SimpleToolStatusBarVisibility {
973
982
  VisibleWhenActive = 1,
974
983
  }
975
984
 
985
+ export enum SpeedSettingsProperty {
986
+ FlySpeedMultiplier = 'FlySpeedMultiplier',
987
+ }
988
+
976
989
  export enum SplineType {
977
990
  Line = 0,
978
991
  Hermite = 1,
@@ -1079,6 +1092,11 @@ export enum WidgetMouseButtonActionType {
1079
1092
  export type GraphicsSettingsPropertyTypeMap = {
1080
1093
  [GraphicsSettingsProperty.ShowInvisibleBlocks]?: boolean;
1081
1094
  [GraphicsSettingsProperty.ShowChunkBoundaries]?: boolean;
1095
+ [GraphicsSettingsProperty.ShowCompass]?: boolean;
1096
+ };
1097
+
1098
+ export type SpeedSettingsPropertyTypeMap = {
1099
+ [SpeedSettingsProperty.FlySpeedMultiplier]?: number;
1082
1100
  };
1083
1101
 
1084
1102
  /**
@@ -1489,6 +1507,20 @@ export class BlockPaletteManager {
1489
1507
  setSelectedItem(item: IBlockPaletteItem): void;
1490
1508
  }
1491
1509
 
1510
+ export class BlockUtilities {
1511
+ private constructor();
1512
+ /**
1513
+ * @remarks
1514
+ * This function can't be called in read-only mode.
1515
+ *
1516
+ * @throws This function can throw errors.
1517
+ */
1518
+ fillVolume(
1519
+ volume: minecraftserver.BlockVolumeBase | minecraftserver.CompoundBlockVolume | Selection,
1520
+ block?: minecraftserver.BlockPermutation | minecraftserver.BlockType | string,
1521
+ ): void;
1522
+ }
1523
+
1492
1524
  export class BrushShapeManager {
1493
1525
  private constructor();
1494
1526
  readonly activeBrushShape?: BrushShape;
@@ -1574,6 +1606,18 @@ export class BrushShapeManager {
1574
1606
  *
1575
1607
  */
1576
1608
  setBrushShapeOffset(offset: minecraftserver.Vector3): void;
1609
+ /**
1610
+ * @remarks
1611
+ * This function can't be called in read-only mode.
1612
+ *
1613
+ */
1614
+ setBrushShapeVisible(visible: boolean): void;
1615
+ /**
1616
+ * @remarks
1617
+ * This function can't be called in read-only mode.
1618
+ *
1619
+ */
1620
+ setSmoothStrength(smoothStrength: number): void;
1577
1621
  /**
1578
1622
  * @remarks
1579
1623
  * This function can't be called in read-only mode.
@@ -1661,7 +1705,7 @@ export class ClipboardItem {
1661
1705
  clear(): void;
1662
1706
  /**
1663
1707
  * @remarks
1664
- * Create a {@link @minecraft/server.CompoundBlockVolume}
1708
+ * Create a {@link minecraftserver.CompoundBlockVolume}
1665
1709
  * container which represents the occupied block volumes within
1666
1710
  * the ClipboardItem.
1667
1711
  * This function does not perform any write operations, and
@@ -1679,7 +1723,7 @@ export class ClipboardItem {
1679
1723
  * An optional set of write parameters which govern how the
1680
1724
  * ClipboardItem should be potentially applied to the world
1681
1725
  * @returns
1682
- * A {@link @minecraft/server.CompoundBlockVolume} which
1726
+ * A {@link minecraftserver.CompoundBlockVolume} which
1683
1727
  * represents the occupied block volumes within the
1684
1728
  * ClipboardItem as they would be written to the world with the
1685
1729
  * specified {@link ClipboardWriteOptions}
@@ -2188,6 +2232,7 @@ export class ExtensionContext {
2188
2232
  */
2189
2233
  readonly afterEvents: ExtensionContextAfterEvents;
2190
2234
  readonly blockPalette: BlockPaletteManager;
2235
+ readonly blockUtilities: BlockUtilities;
2191
2236
  readonly brushShapeManager: BrushShapeManager;
2192
2237
  /**
2193
2238
  * @remarks
@@ -2319,7 +2364,7 @@ export class GraphicsSettings {
2319
2364
  export class IBlockPaletteItem {
2320
2365
  private constructor();
2321
2366
  getBlock(): minecraftserver.BlockType | undefined;
2322
- getDisplayName(): string;
2367
+ getDisplayName(): string | undefined;
2323
2368
  getType(): BlockPaletteItemType;
2324
2369
  /**
2325
2370
  * @remarks
@@ -2723,7 +2768,7 @@ export class Selection {
2723
2768
  *
2724
2769
  * @param forceRelativity
2725
2770
  * See the description for {@link
2726
- * @minecraft/server.CompoundBlockVolume.peekLastVolume}
2771
+ * minecraftserver.CompoundBlockVolume.peekLastVolume}
2727
2772
  * @returns
2728
2773
  * Returns undefined if the stack is empty
2729
2774
  */
@@ -2763,10 +2808,10 @@ export class Selection {
2763
2808
  * This function can't be called in read-only mode.
2764
2809
  *
2765
2810
  * @param other
2766
- * {@link @minecraft/server.CompoundBlockVolume} - set the
2767
- * block component part of this selection to the specified
2768
- * compound block volume. This will completely replace all
2769
- * block volume definitions in the selection.
2811
+ * {@link minecraftserver.CompoundBlockVolume} - set the block
2812
+ * component part of this selection to the specified compound
2813
+ * block volume. This will completely replace all block volume
2814
+ * definitions in the selection.
2770
2815
  * {@link Selection} - replace the selection with the specified
2771
2816
  * selection
2772
2817
  * @throws This function can throw errors.
@@ -2843,6 +2888,7 @@ export class SettingsManager {
2843
2888
  *
2844
2889
  */
2845
2890
  readonly graphics: GraphicsSettings;
2891
+ readonly speed: SpeedSettings;
2846
2892
  readonly theme: ThemeSettings;
2847
2893
  }
2848
2894
 
@@ -2929,6 +2975,20 @@ export class SimulationState {
2929
2975
  setPaused(isPaused: boolean): void;
2930
2976
  }
2931
2977
 
2978
+ export class SpeedSettings {
2979
+ private constructor();
2980
+ get<T extends keyof SpeedSettingsPropertyTypeMap>(property: T): SpeedSettingsPropertyTypeMap[T] | undefined;
2981
+ getAll(): SpeedSettingsPropertyTypeMap;
2982
+ /**
2983
+ * @throws This function can throw errors.
2984
+ */
2985
+ set<T extends keyof SpeedSettingsPropertyTypeMap>(property: T, value: SpeedSettingsPropertyTypeMap[T]): void;
2986
+ /**
2987
+ * @throws This function can throw errors.
2988
+ */
2989
+ setAll(properties: SpeedSettingsPropertyTypeMap): void;
2990
+ }
2991
+
2932
2992
  export class ThemeSettings {
2933
2993
  private constructor();
2934
2994
  /**
@@ -3147,7 +3207,7 @@ export class TransactionManager {
3147
3207
  /**
3148
3208
  * @remarks
3149
3209
  * Begin tracking block changes in an area defined by a {@link
3150
- * @minecraft/server.CompoundBlockVolume}. These will be added
3210
+ * minecraftserver.CompoundBlockVolume}. These will be added
3151
3211
  * to a pending changes list.
3152
3212
  * The pending list will be added to the open transaction
3153
3213
  * record when a commit has been issued.
@@ -3155,8 +3215,8 @@ export class TransactionManager {
3155
3215
  * This function can't be called in read-only mode.
3156
3216
  *
3157
3217
  * @param compoundBlockVolume
3158
- * {@link @minecraft/server.CompoundBlockVolume} to track.
3159
- * Only non-void block locations will be tracked -- any changes
3218
+ * {@link minecraftserver.CompoundBlockVolume} to track. Only
3219
+ * non-void block locations will be tracked -- any changes
3160
3220
  * falling into a void/negative space will not be tracked
3161
3221
  * @throws This function can throw errors.
3162
3222
  */
@@ -3183,8 +3243,8 @@ export class TransactionManager {
3183
3243
  * Selection Volumes can also represent irregular shapes with
3184
3244
  * non-contiguous blocks and this tracking call will honor the
3185
3245
  * actual selected areas in the volume (and not the negative
3186
- * space) (see {@link @minecraft/server.CompoundBlockVolume}
3187
- * for more details
3246
+ * space) (see {@link minecraftserver.CompoundBlockVolume} for
3247
+ * more details
3188
3248
  *
3189
3249
  * This function can't be called in read-only mode.
3190
3250
  *
@@ -4204,7 +4264,10 @@ export interface WidgetComponentEntityOptions extends WidgetComponentBaseOptions
4204
4264
  }
4205
4265
 
4206
4266
  // @ts-ignore Class inheritance allowed for native defined classes
4207
- export interface WidgetComponentGizmoOptions extends WidgetComponentBaseOptions {}
4267
+ export interface WidgetComponentGizmoOptions extends WidgetComponentBaseOptions {
4268
+ axes?: Axis;
4269
+ enablePlanes?: boolean;
4270
+ }
4208
4271
 
4209
4272
  // @ts-ignore Class inheritance allowed for native defined classes
4210
4273
  export interface WidgetComponentGuideOptions extends WidgetComponentBaseOptions {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@minecraft/server-editor",
3
- "version": "0.1.0-beta.1.21.50-preview.26",
3
+ "version": "0.1.0-beta.1.21.50-preview.28",
4
4
  "description": "",
5
5
  "contributors": [
6
6
  {
@@ -14,7 +14,7 @@
14
14
  ],
15
15
  "dependencies": {
16
16
  "@minecraft/common": "^1.0.0",
17
- "@minecraft/server": "^1.17.0-beta.1.21.50-preview.26"
17
+ "@minecraft/server": "^1.17.0-beta.1.21.50-preview.28"
18
18
  },
19
19
  "license": "MIT"
20
20
  }