@onimaxxing/worldgen-node 0.21.3 → 0.22.0
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/README.md +2 -5
- package/index.d.ts +18 -24
- package/oni_wasm_bg.wasm +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -143,15 +143,12 @@ touch the cluster cache.
|
|
|
143
143
|
|
|
144
144
|
`opts.worlds` selects by placement index or world path (full path or
|
|
145
145
|
last segment, matched after mixing). Selectors that match nothing come
|
|
146
|
-
back in `absent` rather than erroring.
|
|
147
|
-
|
|
148
|
-
pre-settle; for settled state use `worldgen.generate` +
|
|
149
|
-
`worldgen.advance`.
|
|
146
|
+
back in `absent` rather than erroring. Cell grids are pre-settle; for
|
|
147
|
+
settled state use `worldgen.generate` + `worldgen.advance`.
|
|
150
148
|
|
|
151
149
|
```ts
|
|
152
150
|
const r = worldgen.partials('V-SNDST-C-42-0-4A-MUWF1', {
|
|
153
151
|
worlds: ['VanillaSandstoneDefault'],
|
|
154
|
-
omit: ['cells', 'biomes', 'spawners'],
|
|
155
152
|
});
|
|
156
153
|
for (const g of r.worlds[0]?.geysers ?? []) console.log(g.type, g.x, g.y);
|
|
157
154
|
```
|
package/index.d.ts
CHANGED
|
@@ -467,18 +467,12 @@ export interface PartialsOptions {
|
|
|
467
467
|
worlds: Array<number | string>;
|
|
468
468
|
/** `"templates"` (default) or `"notemplates"` (skip template placement). */
|
|
469
469
|
mode?: 'templates' | 'notemplates';
|
|
470
|
-
/**
|
|
471
|
-
* Payload blocks to drop. Serialization only; generation cost is
|
|
472
|
-
* identical. Geysers and traits are always included.
|
|
473
|
-
*/
|
|
474
|
-
omit?: Array<'cells' | 'biomes' | 'spawners'>;
|
|
475
470
|
}
|
|
476
471
|
|
|
477
472
|
/**
|
|
478
473
|
* One generated world from `worldgen.partials`. Grid fields arrive as
|
|
479
|
-
* plain JSON arrays (not the typed arrays `generate` uses)
|
|
480
|
-
* pre-settle state
|
|
481
|
-
* block was requested.
|
|
474
|
+
* plain JSON arrays (not the typed arrays `generate` uses) and hold
|
|
475
|
+
* pre-settle state.
|
|
482
476
|
*/
|
|
483
477
|
export interface PartialWorld {
|
|
484
478
|
/** Placement index in the cluster layout (stable slot identity). */
|
|
@@ -504,22 +498,22 @@ export interface PartialWorld {
|
|
|
504
498
|
geyser_spawns_count: number;
|
|
505
499
|
geyser_stats_sha: string;
|
|
506
500
|
geyser_stats_count: number;
|
|
507
|
-
element_idx
|
|
508
|
-
mass
|
|
509
|
-
temperature
|
|
510
|
-
disease_idx
|
|
511
|
-
disease_count
|
|
512
|
-
backwall_element_idx
|
|
513
|
-
backwall_mass
|
|
514
|
-
backwall_temperature
|
|
515
|
-
zone_idx
|
|
516
|
-
zone_table
|
|
517
|
-
subworld_idx
|
|
518
|
-
subworld_table
|
|
519
|
-
biome_cells
|
|
520
|
-
buildings
|
|
521
|
-
pickupables
|
|
522
|
-
other_entities
|
|
501
|
+
element_idx: number[];
|
|
502
|
+
mass: number[];
|
|
503
|
+
temperature: number[];
|
|
504
|
+
disease_idx: number[];
|
|
505
|
+
disease_count: number[];
|
|
506
|
+
backwall_element_idx: number[];
|
|
507
|
+
backwall_mass: number[];
|
|
508
|
+
backwall_temperature: number[];
|
|
509
|
+
zone_idx: number[];
|
|
510
|
+
zone_table: string[];
|
|
511
|
+
subworld_idx: number[];
|
|
512
|
+
subworld_table: string[];
|
|
513
|
+
biome_cells: BiomeCell[];
|
|
514
|
+
buildings: EntitySpawn[];
|
|
515
|
+
pickupables: EntitySpawn[];
|
|
516
|
+
other_entities: EntitySpawn[];
|
|
523
517
|
}
|
|
524
518
|
|
|
525
519
|
export interface PartialsMixingApplied {
|
package/oni_wasm_bg.wasm
CHANGED
|
Binary file
|