@minecraft/server 1.7.0-rc.1.20.50-preview.21 → 1.7.0-rc.1.20.50-preview.22
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.
- package/index.d.ts +53 -10
- package/package.json +2 -2
package/index.d.ts
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
* ```json
|
|
17
17
|
* {
|
|
18
18
|
* "module_name": "@minecraft/server",
|
|
19
|
-
* "version": "1.8.0-internal.1.20.50-preview.
|
|
19
|
+
* "version": "1.8.0-internal.1.20.50-preview.22"
|
|
20
20
|
* }
|
|
21
21
|
* ```
|
|
22
22
|
*
|
|
@@ -2362,10 +2362,8 @@ export class Entity {
|
|
|
2362
2362
|
/**
|
|
2363
2363
|
* @beta
|
|
2364
2364
|
* @remarks
|
|
2365
|
-
* Returns all tags associated with an entity.
|
|
2366
|
-
*
|
|
2367
2365
|
* @returns
|
|
2368
|
-
* Returns
|
|
2366
|
+
* Returns all tags associated with an entity.
|
|
2369
2367
|
* @throws This function can throw errors.
|
|
2370
2368
|
*/
|
|
2371
2369
|
getTags(): string[];
|
|
@@ -2471,6 +2469,14 @@ export class Entity {
|
|
|
2471
2469
|
kill(): boolean;
|
|
2472
2470
|
/**
|
|
2473
2471
|
* @beta
|
|
2472
|
+
* @remarks
|
|
2473
|
+
* Matches the entity against the passed in options. Uses the
|
|
2474
|
+
* location of the entity for matching if the location is not
|
|
2475
|
+
* specified in the passed in EntityQueryOptions.
|
|
2476
|
+
*
|
|
2477
|
+
* @returns
|
|
2478
|
+
* Returns true if the entity matches the criteria in the
|
|
2479
|
+
* passed in EntityQueryOptions, otherwise it returns false.
|
|
2474
2480
|
* @throws This function can throw errors.
|
|
2475
2481
|
*/
|
|
2476
2482
|
matches(options: EntityQueryOptions): boolean;
|
|
@@ -3314,11 +3320,12 @@ export class EntityInventoryComponent extends EntityComponent {
|
|
|
3314
3320
|
readonly canBeSiphonedFrom: boolean;
|
|
3315
3321
|
/**
|
|
3316
3322
|
* @remarks
|
|
3317
|
-
* Defines the container for this entity.
|
|
3323
|
+
* Defines the container for this entity. The container will be
|
|
3324
|
+
* undefined if the entity has been removed.
|
|
3318
3325
|
*
|
|
3319
3326
|
* @throws This property can throw when used.
|
|
3320
3327
|
*/
|
|
3321
|
-
readonly container
|
|
3328
|
+
readonly container?: Container;
|
|
3322
3329
|
/**
|
|
3323
3330
|
* @remarks
|
|
3324
3331
|
* Type of container this entity has.
|
|
@@ -4625,10 +4632,12 @@ export class ItemStartUseOnAfterEvent {
|
|
|
4625
4632
|
readonly blockFace: Direction;
|
|
4626
4633
|
/**
|
|
4627
4634
|
* @remarks
|
|
4628
|
-
* The impacted item stack that is starting to be used.
|
|
4635
|
+
* The impacted item stack that is starting to be used. Can be
|
|
4636
|
+
* undefined in some gameplay scenarios like pushing a button
|
|
4637
|
+
* with an empty hand.
|
|
4629
4638
|
*
|
|
4630
4639
|
*/
|
|
4631
|
-
readonly itemStack
|
|
4640
|
+
readonly itemStack?: ItemStack;
|
|
4632
4641
|
/**
|
|
4633
4642
|
* @remarks
|
|
4634
4643
|
* Returns the source entity that triggered this item event.
|
|
@@ -4676,9 +4685,11 @@ export class ItemStopUseAfterEvent {
|
|
|
4676
4685
|
/**
|
|
4677
4686
|
* @remarks
|
|
4678
4687
|
* The impacted item stack that is stopping being charged.
|
|
4688
|
+
* ItemStopUseAfterEvent can be called when teleporting to a
|
|
4689
|
+
* different dimension and this can be undefined.
|
|
4679
4690
|
*
|
|
4680
4691
|
*/
|
|
4681
|
-
readonly itemStack
|
|
4692
|
+
readonly itemStack?: ItemStack;
|
|
4682
4693
|
/**
|
|
4683
4694
|
* @remarks
|
|
4684
4695
|
* Returns the source entity that triggered this item event.
|
|
@@ -5632,11 +5643,16 @@ export class PlayerInteractWithBlockAfterEvent {
|
|
|
5632
5643
|
|
|
5633
5644
|
/**
|
|
5634
5645
|
* @beta
|
|
5646
|
+
* Manages callbacks that are connected to after a player
|
|
5647
|
+
* interacts with a block.
|
|
5635
5648
|
*/
|
|
5636
5649
|
export class PlayerInteractWithBlockAfterEventSignal {
|
|
5637
5650
|
private constructor();
|
|
5638
5651
|
/**
|
|
5639
5652
|
* @remarks
|
|
5653
|
+
* Adds a callback that will be called after a player interacts
|
|
5654
|
+
* with a block.
|
|
5655
|
+
*
|
|
5640
5656
|
* This function can't be called in read-only mode.
|
|
5641
5657
|
*
|
|
5642
5658
|
*/
|
|
@@ -5645,6 +5661,9 @@ export class PlayerInteractWithBlockAfterEventSignal {
|
|
|
5645
5661
|
): (arg: PlayerInteractWithBlockAfterEvent) => void;
|
|
5646
5662
|
/**
|
|
5647
5663
|
* @remarks
|
|
5664
|
+
* Removes a callback from being called after a player
|
|
5665
|
+
* interacts with a block.
|
|
5666
|
+
*
|
|
5648
5667
|
* This function can't be called in read-only mode.
|
|
5649
5668
|
*
|
|
5650
5669
|
* @throws This function can throw errors.
|
|
@@ -5701,11 +5720,16 @@ export class PlayerInteractWithBlockBeforeEvent {
|
|
|
5701
5720
|
|
|
5702
5721
|
/**
|
|
5703
5722
|
* @beta
|
|
5723
|
+
* Manages callbacks that are connected to before a player
|
|
5724
|
+
* interacts with a block.
|
|
5704
5725
|
*/
|
|
5705
5726
|
export class PlayerInteractWithBlockBeforeEventSignal {
|
|
5706
5727
|
private constructor();
|
|
5707
5728
|
/**
|
|
5708
5729
|
* @remarks
|
|
5730
|
+
* Adds a callback that will be called before a player
|
|
5731
|
+
* interacts with a block.
|
|
5732
|
+
*
|
|
5709
5733
|
* This function can't be called in read-only mode.
|
|
5710
5734
|
*
|
|
5711
5735
|
*/
|
|
@@ -5714,6 +5738,9 @@ export class PlayerInteractWithBlockBeforeEventSignal {
|
|
|
5714
5738
|
): (arg: PlayerInteractWithBlockBeforeEvent) => void;
|
|
5715
5739
|
/**
|
|
5716
5740
|
* @remarks
|
|
5741
|
+
* Removes a callback from being called before a player
|
|
5742
|
+
* interacts with a block.
|
|
5743
|
+
*
|
|
5717
5744
|
* This function can't be called in read-only mode.
|
|
5718
5745
|
*
|
|
5719
5746
|
* @throws This function can throw errors.
|
|
@@ -5751,11 +5778,16 @@ export class PlayerInteractWithEntityAfterEvent {
|
|
|
5751
5778
|
|
|
5752
5779
|
/**
|
|
5753
5780
|
* @beta
|
|
5781
|
+
* Manages callbacks that are connected to after a player
|
|
5782
|
+
* interacts with an entity.
|
|
5754
5783
|
*/
|
|
5755
5784
|
export class PlayerInteractWithEntityAfterEventSignal {
|
|
5756
5785
|
private constructor();
|
|
5757
5786
|
/**
|
|
5758
5787
|
* @remarks
|
|
5788
|
+
* Adds a callback that will be called after a player interacts
|
|
5789
|
+
* with an entity.
|
|
5790
|
+
*
|
|
5759
5791
|
* This function can't be called in read-only mode.
|
|
5760
5792
|
*
|
|
5761
5793
|
*/
|
|
@@ -5764,6 +5796,9 @@ export class PlayerInteractWithEntityAfterEventSignal {
|
|
|
5764
5796
|
): (arg: PlayerInteractWithEntityAfterEvent) => void;
|
|
5765
5797
|
/**
|
|
5766
5798
|
* @remarks
|
|
5799
|
+
* Removes a callback from being called after a player
|
|
5800
|
+
* interacts with an entity.
|
|
5801
|
+
*
|
|
5767
5802
|
* This function can't be called in read-only mode.
|
|
5768
5803
|
*
|
|
5769
5804
|
* @throws This function can throw errors.
|
|
@@ -5807,11 +5842,16 @@ export class PlayerInteractWithEntityBeforeEvent {
|
|
|
5807
5842
|
|
|
5808
5843
|
/**
|
|
5809
5844
|
* @beta
|
|
5845
|
+
* Manages callbacks that are connected to before a player
|
|
5846
|
+
* interacts with an entity.
|
|
5810
5847
|
*/
|
|
5811
5848
|
export class PlayerInteractWithEntityBeforeEventSignal {
|
|
5812
5849
|
private constructor();
|
|
5813
5850
|
/**
|
|
5814
5851
|
* @remarks
|
|
5852
|
+
* Adds a callback that will be called before a player
|
|
5853
|
+
* interacts with an entity.
|
|
5854
|
+
*
|
|
5815
5855
|
* This function can't be called in read-only mode.
|
|
5816
5856
|
*
|
|
5817
5857
|
*/
|
|
@@ -5820,6 +5860,9 @@ export class PlayerInteractWithEntityBeforeEventSignal {
|
|
|
5820
5860
|
): (arg: PlayerInteractWithEntityBeforeEvent) => void;
|
|
5821
5861
|
/**
|
|
5822
5862
|
* @remarks
|
|
5863
|
+
* Removes a callback from being called before a player
|
|
5864
|
+
* interacts with an entity.
|
|
5865
|
+
*
|
|
5823
5866
|
* This function can't be called in read-only mode.
|
|
5824
5867
|
*
|
|
5825
5868
|
* @throws This function can throw errors.
|
|
@@ -7979,7 +8022,7 @@ export interface EntityHitInformation {
|
|
|
7979
8022
|
* Entity that was hit.
|
|
7980
8023
|
*
|
|
7981
8024
|
*/
|
|
7982
|
-
entity
|
|
8025
|
+
entity?: Entity;
|
|
7983
8026
|
}
|
|
7984
8027
|
|
|
7985
8028
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@minecraft/server",
|
|
3
|
-
"version": "1.7.0-rc.1.20.50-preview.
|
|
3
|
+
"version": "1.7.0-rc.1.20.50-preview.22",
|
|
4
4
|
"description": "",
|
|
5
5
|
"contributors": [
|
|
6
6
|
{
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
}
|
|
14
14
|
],
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"@minecraft/common": "^1.1.0-rc.1.20.50-preview.
|
|
16
|
+
"@minecraft/common": "^1.1.0-rc.1.20.50-preview.22"
|
|
17
17
|
},
|
|
18
18
|
"license": "MIT"
|
|
19
19
|
}
|