bc-minecraft-bedrock-project 1.21.100-0 → 1.21.100-1
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/lib/src/internal/behavior-pack/index.d.ts +1 -0
- package/lib/src/internal/behavior-pack/index.js +1 -0
- package/lib/src/internal/behavior-pack/index.js.map +1 -1
- package/lib/src/internal/behavior-pack/spawn_rule.d.ts +26 -0
- package/lib/src/internal/behavior-pack/spawn_rule.js +25 -0
- package/lib/src/internal/behavior-pack/spawn_rule.js.map +1 -0
- package/package.json +1 -1
|
@@ -25,4 +25,5 @@ __exportStar(require("./feature"), exports);
|
|
|
25
25
|
__exportStar(require("./feature_rule"), exports);
|
|
26
26
|
__exportStar(require("./item_catalog"), exports);
|
|
27
27
|
__exportStar(require("./recipe"), exports);
|
|
28
|
+
__exportStar(require("./spawn_rule"), exports);
|
|
28
29
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/internal/behavior-pack/index.ts"],"names":[],"mappings":";AAAA,oBAAoB;;;;;;;;;;;;;;;;AAEpB,8CAA4B;AAC5B,yDAAuC;AACvC,0CAAwB;AACxB,0CAAwB;AACxB,2CAAyB;AACzB,yCAAuB;AACvB,4CAA0B;AAC1B,iDAA+B;AAC/B,iDAA+B;AAC/B,2CAAyB"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/internal/behavior-pack/index.ts"],"names":[],"mappings":";AAAA,oBAAoB;;;;;;;;;;;;;;;;AAEpB,8CAA4B;AAC5B,yDAAuC;AACvC,0CAAwB;AACxB,0CAAwB;AACxB,2CAAyB;AACzB,yCAAuB;AACvB,4CAA0B;AAC1B,iDAA+B;AAC/B,iDAA+B;AAC/B,2CAAyB;AACzB,+CAA6B"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { ComponentContainer } from 'bc-minecraft-bedrock-types/lib/minecraft/components';
|
|
2
|
+
import { FormatVersion } from "../types/format-version";
|
|
3
|
+
/** */
|
|
4
|
+
export interface SpawnRule extends Readonly<FormatVersion> {
|
|
5
|
+
/** */
|
|
6
|
+
format_version: string;
|
|
7
|
+
/** */
|
|
8
|
+
"minecraft:spawn_rules": {
|
|
9
|
+
description: {
|
|
10
|
+
identifier: string;
|
|
11
|
+
population_control: string;
|
|
12
|
+
};
|
|
13
|
+
conditions: ComponentContainer[];
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
*/
|
|
19
|
+
export declare namespace SpawnRule {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @param value
|
|
23
|
+
* @returns
|
|
24
|
+
*/
|
|
25
|
+
function is(value: any): value is SpawnRule;
|
|
26
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SpawnRule = void 0;
|
|
4
|
+
/**
|
|
5
|
+
*
|
|
6
|
+
*/
|
|
7
|
+
var SpawnRule;
|
|
8
|
+
(function (SpawnRule) {
|
|
9
|
+
/**
|
|
10
|
+
*
|
|
11
|
+
* @param value
|
|
12
|
+
* @returns
|
|
13
|
+
*/
|
|
14
|
+
function is(value) {
|
|
15
|
+
if (typeof value === "object" && typeof value.format_version === "string" && typeof value["minecraft:spawn_rules"] === "object") {
|
|
16
|
+
const desc = value["minecraft:spawn_rules"].description;
|
|
17
|
+
if (typeof desc === "object" && typeof desc.identifier === "string" && Array.isArray(value['minecraft:spawn_rules'].conditions)) {
|
|
18
|
+
return true;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
return false;
|
|
22
|
+
}
|
|
23
|
+
SpawnRule.is = is;
|
|
24
|
+
})(SpawnRule || (exports.SpawnRule = SpawnRule = {}));
|
|
25
|
+
//# sourceMappingURL=spawn_rule.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"spawn_rule.js","sourceRoot":"","sources":["../../../../src/internal/behavior-pack/spawn_rule.ts"],"names":[],"mappings":";;;AAiBA;;GAEG;AACH,IAAiB,SAAS,CAiBzB;AAjBD,WAAiB,SAAS;IACxB;;;;OAIG;IACH,SAAgB,EAAE,CAAC,KAAU;QAC3B,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,OAAO,KAAK,CAAC,cAAc,KAAK,QAAQ,IAAI,OAAO,KAAK,CAAC,uBAAuB,CAAC,KAAK,QAAQ,EAAE,CAAC;YAChI,MAAM,IAAI,GAAG,KAAK,CAAC,uBAAuB,CAAC,CAAC,WAAW,CAAC;YAExD,IAAI,OAAO,IAAI,KAAK,QAAQ,IAAI,OAAO,IAAI,CAAC,UAAU,KAAK,QAAQ,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAC,UAAU,CAAC,EAAE,CAAC;gBAChI,OAAO,IAAI,CAAC;YACd,CAAC;QACH,CAAC;QAED,OAAO,KAAK,CAAC;IACf,CAAC;IAVe,YAAE,KAUjB,CAAA;AACH,CAAC,EAjBgB,SAAS,yBAAT,SAAS,QAiBzB"}
|
package/package.json
CHANGED