@nodecraft/rendermite 1.2.1 → 1.3.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/README.md +8 -0
- package/dist/blocks/blockstate-eval.d.ts +1 -1
- package/dist/blocks/cli.js +1 -1
- package/dist/blocks/export.js +1 -1
- package/dist/blocks/pack-format.d.ts +2 -0
- package/dist/blocks/pack-format.js +1 -0
- package/dist/{blockstate-eval-CObtPWzJ.d.ts → blockstate-eval-BzznRcVY.d.ts} +23 -9
- package/dist/{cli-CWUKXFbx.js → cli-BaoVzDGo.js} +1 -1
- package/dist/cli.js +1 -1
- package/dist/{export-DY5sGwt0.js → export-BNvYiw6i.js} +27 -18
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/pack-format-CfCP4kzy.d.ts +131 -0
- package/dist/pack.d.ts +5 -0
- package/dist/pack.js +2 -0
- package/package.json +6 -1
package/README.md
CHANGED
|
@@ -91,6 +91,14 @@ Everything the CLI does is exported, from the high-level `run()` and `exportBloc
|
|
|
91
91
|
import { run, exportBlockPack, prepareModResources, builtinPackPath } from '@nodecraft/rendermite';
|
|
92
92
|
```
|
|
93
93
|
|
|
94
|
+
Reading a published block pack needs none of that toolchain, so it has its own entry — no `sharp`,
|
|
95
|
+
no `node:` builtin, 13 KB bundled:
|
|
96
|
+
|
|
97
|
+
```ts
|
|
98
|
+
import { evaluateBlockState } from '@nodecraft/rendermite/pack';
|
|
99
|
+
import type { BlockPackModel } from '@nodecraft/rendermite/pack';
|
|
100
|
+
```
|
|
101
|
+
|
|
94
102
|
## Performance
|
|
95
103
|
|
|
96
104
|
Benchmarked against PHP renderchest v5.1.0 on the same machine, rendering the same extracted 1.21.8 assets at 64px (PNG + WebP):
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as BlockStateMultipartCase, c as ParseBlockStateOptions, d as matchesCondition, f as parseBlockState, i as BlockStateError, l as collectModels, n as BlockProperties, o as BlockStateVariantCase, p as weightedVariantIndex, r as BlockStateDefinition, s as MultipartCondition, t as BlockModelVariant, u as evaluateBlockState } from "../blockstate-eval-
|
|
1
|
+
import { a as BlockStateMultipartCase, c as ParseBlockStateOptions, d as matchesCondition, f as parseBlockState, i as BlockStateError, l as collectModels, n as BlockProperties, o as BlockStateVariantCase, p as weightedVariantIndex, r as BlockStateDefinition, s as MultipartCondition, t as BlockModelVariant, u as evaluateBlockState } from "../blockstate-eval-BzznRcVY.js";
|
|
2
2
|
export { BlockModelVariant, BlockProperties, BlockStateDefinition, BlockStateError, BlockStateMultipartCase, BlockStateVariantCase, MultipartCondition, ParseBlockStateOptions, collectModels, evaluateBlockState, matchesCondition, parseBlockState, weightedVariantIndex };
|
package/dist/blocks/cli.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as runBlocksCli } from "../cli-
|
|
1
|
+
import { t as runBlocksCli } from "../cli-BaoVzDGo.js";
|
|
2
2
|
export { runBlocksCli };
|
package/dist/blocks/export.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { t as exportBlockPack } from "../export-
|
|
1
|
+
import { t as exportBlockPack } from "../export-BNvYiw6i.js";
|
|
2
2
|
export { exportBlockPack };
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { a as BlockPackElement, c as BlockPackModel, d as BlockPackSprite, f as BlockPackSpriteFrame, i as BlockPackBlockStatesFile, l as BlockPackModelsFile, m as BlockPackVariant, n as BlockPackAtlasPage, o as BlockPackFace, p as BlockPackTintsFile, r as BlockPackBlockState, s as BlockPackMetaFile, t as BlockPackAtlasFile, u as BlockPackRenderLayer } from "../pack-format-CfCP4kzy.js";
|
|
2
|
+
export { BlockPackAtlasFile, BlockPackAtlasPage, BlockPackBlockState, BlockPackBlockStatesFile, BlockPackElement, BlockPackFace, BlockPackMetaFile, BlockPackModel, BlockPackModelsFile, BlockPackRenderLayer, BlockPackSprite, BlockPackSpriteFrame, BlockPackTintsFile, BlockPackVariant };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -32,11 +32,19 @@ interface BlockModelVariant {
|
|
|
32
32
|
/** Relative weight within its list; the game picks one per block position. */
|
|
33
33
|
weight: number;
|
|
34
34
|
}
|
|
35
|
-
/**
|
|
36
|
-
|
|
35
|
+
/**
|
|
36
|
+
* One entry of a `variants` map, with its `a=b,c=d` key already parsed.
|
|
37
|
+
*
|
|
38
|
+
* Generic over the variant because the evaluation reads only `model`: a pack
|
|
39
|
+
* consumer holds variants whose rotations are optional (the emit omits them at
|
|
40
|
+
* their defaults) and can evaluate those directly, getting its own shape back.
|
|
41
|
+
*/
|
|
42
|
+
interface BlockStateVariantCase<Variant extends {
|
|
43
|
+
model: string;
|
|
44
|
+
} = BlockModelVariant> {
|
|
37
45
|
/** Properties this case constrains; unstated ones are wildcards. */
|
|
38
46
|
when: Record<string, string>;
|
|
39
|
-
apply:
|
|
47
|
+
apply: Variant[];
|
|
40
48
|
}
|
|
41
49
|
/**
|
|
42
50
|
* A `multipart` predicate. `match` holds one or more accepted values per
|
|
@@ -52,17 +60,21 @@ type MultipartCondition = {
|
|
|
52
60
|
op: 'or';
|
|
53
61
|
terms: MultipartCondition[];
|
|
54
62
|
};
|
|
55
|
-
interface BlockStateMultipartCase {
|
|
63
|
+
interface BlockStateMultipartCase<Variant extends {
|
|
64
|
+
model: string;
|
|
65
|
+
} = BlockModelVariant> {
|
|
56
66
|
/** null for an unconditional part, which always applies. */
|
|
57
67
|
when: MultipartCondition | null;
|
|
58
|
-
apply:
|
|
68
|
+
apply: Variant[];
|
|
59
69
|
}
|
|
60
|
-
type BlockStateDefinition
|
|
70
|
+
type BlockStateDefinition<Variant extends {
|
|
71
|
+
model: string;
|
|
72
|
+
} = BlockModelVariant> = {
|
|
61
73
|
kind: 'variants';
|
|
62
|
-
cases: BlockStateVariantCase
|
|
74
|
+
cases: Array<BlockStateVariantCase<Variant>>;
|
|
63
75
|
} | {
|
|
64
76
|
kind: 'multipart';
|
|
65
|
-
cases: BlockStateMultipartCase
|
|
77
|
+
cases: Array<BlockStateMultipartCase<Variant>>;
|
|
66
78
|
};
|
|
67
79
|
declare class BlockStateError extends Error {}
|
|
68
80
|
interface ParseBlockStateOptions {
|
|
@@ -104,7 +116,9 @@ declare function matchesCondition(condition: MultipartCondition, properties: Blo
|
|
|
104
116
|
* Still empty when even that finds nothing, which is a real answer: a blockstate
|
|
105
117
|
* that covers only some of a block's states draws nothing for the rest.
|
|
106
118
|
*/
|
|
107
|
-
declare function evaluateBlockState
|
|
119
|
+
declare function evaluateBlockState<Variant extends {
|
|
120
|
+
model: string;
|
|
121
|
+
}>(definition: BlockStateDefinition<Variant>, properties: BlockProperties): Variant[][];
|
|
108
122
|
/** Every model a blockstate can name, for deciding what to export. */
|
|
109
123
|
declare function collectModels(definition: BlockStateDefinition): string[];
|
|
110
124
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as builtinPackPath } from "./builtin-WkWjATeh.js";
|
|
2
2
|
import { n as LayeredResourceManager, t as FolderResourceManager } from "./manager-CYbAkWuT.js";
|
|
3
|
-
import { t as exportBlockPack } from "./export-
|
|
3
|
+
import { t as exportBlockPack } from "./export-BNvYiw6i.js";
|
|
4
4
|
import { n as prepareModResources } from "./prepare-B8oPdGYz.js";
|
|
5
5
|
import { t as downloadClientJar } from "./download-1wAfrGKx.js";
|
|
6
6
|
import { a as prepareVersionResources, r as compareVersions } from "./prepare-C95vjt_o.js";
|
package/dist/cli.js
CHANGED
|
@@ -6,7 +6,7 @@ import { n as harvestTintOverrides, t as curatedTintOverrides } from "./tints-nx
|
|
|
6
6
|
import { t as JarResourceManager } from "./jar-5aLDI0nT.js";
|
|
7
7
|
import { t as downloadClientJar } from "./download-1wAfrGKx.js";
|
|
8
8
|
import { a as prepareVersionResources, i as eraForVersion, n as GEOMETRY_DONOR_VERSIONS } from "./prepare-C95vjt_o.js";
|
|
9
|
-
import { t as runBlocksCli } from "./cli-
|
|
9
|
+
import { t as runBlocksCli } from "./cli-BaoVzDGo.js";
|
|
10
10
|
import { t as run } from "./run-Diql5y56.js";
|
|
11
11
|
import path from "node:path";
|
|
12
12
|
import os from "node:os";
|
|
@@ -191,26 +191,35 @@ function translateElements(elements, offset) {
|
|
|
191
191
|
});
|
|
192
192
|
}
|
|
193
193
|
function serializeBlockState(definition, exported) {
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
194
|
+
/** Every default dropped, since most variants state none of these. */
|
|
195
|
+
const serializeApply = (apply) => apply.filter((variant) => exported(variant.model)).map((variant) => {
|
|
196
|
+
return {
|
|
197
|
+
model: variant.model,
|
|
198
|
+
...variant.x !== 0 && { x: variant.x },
|
|
199
|
+
...variant.y !== 0 && { y: variant.y },
|
|
200
|
+
...variant.z !== 0 && { z: variant.z },
|
|
201
|
+
...variant.uvlock && { uvlock: true },
|
|
202
|
+
...variant.weight !== 1 && { weight: variant.weight }
|
|
203
|
+
};
|
|
204
|
+
});
|
|
205
|
+
if (definition.kind === "variants") {
|
|
206
|
+
const cases = definition.cases.flatMap((entry) => {
|
|
207
|
+
const apply = serializeApply(entry.apply);
|
|
208
|
+
return apply.length === 0 ? [] : [{
|
|
209
|
+
when: entry.when,
|
|
210
|
+
apply
|
|
211
|
+
}];
|
|
210
212
|
});
|
|
213
|
+
return cases.length === 0 ? null : { variants: cases };
|
|
211
214
|
}
|
|
212
|
-
|
|
213
|
-
|
|
215
|
+
const cases = definition.cases.flatMap((entry) => {
|
|
216
|
+
const apply = serializeApply(entry.apply);
|
|
217
|
+
return apply.length === 0 ? [] : [{
|
|
218
|
+
when: entry.when,
|
|
219
|
+
apply
|
|
220
|
+
}];
|
|
221
|
+
});
|
|
222
|
+
return cases.length === 0 ? null : { multipart: cases };
|
|
214
223
|
}
|
|
215
224
|
/**
|
|
216
225
|
* Any texture the model binds, for a model that declares no `particle`. Ordered
|
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { a as TextureMeta, i as TextureLoader, o as TextureResolutionError, r as
|
|
|
4
4
|
import { d as parseAtlasSources, n as AtlasSource, r as AtlasSourceError, s as ResolvedSprite, t as AtlasResolver, u as createAtlasResolver } from "./sources-B9X9w3qP.js";
|
|
5
5
|
import { a as PackedRect, i as PackedPage, n as PackOptions, o as packAtlas, r as PackedAtlas, t as PackEntry } from "./atlas-pack-DRTrWcSU.js";
|
|
6
6
|
import { a as resolveTexture, n as ModelResolutionError, o as salvageJson, r as ResolvedModel, t as ModelLoader } from "./loader-C_1_amsq.js";
|
|
7
|
-
import { a as BlockStateMultipartCase, d as matchesCondition, f as parseBlockState, i as BlockStateError, l as collectModels, n as BlockProperties, o as BlockStateVariantCase, p as weightedVariantIndex, r as BlockStateDefinition, s as MultipartCondition, t as BlockModelVariant, u as evaluateBlockState } from "./blockstate-eval-
|
|
7
|
+
import { a as BlockStateMultipartCase, d as matchesCondition, f as parseBlockState, i as BlockStateError, l as collectModels, n as BlockProperties, o as BlockStateVariantCase, p as weightedVariantIndex, r as BlockStateDefinition, s as MultipartCondition, t as BlockModelVariant, u as evaluateBlockState } from "./blockstate-eval-BzznRcVY.js";
|
|
8
8
|
import { i as exportBlockPack, n as BlockPackResult, r as ExportBlockPackOptions, t as BlockPackFailure } from "./export-BIpqNU3H.js";
|
|
9
9
|
import { i as buildObjMesh, n as ObjMesh, r as ObjMeshError, t as MeshGroup } from "./obj-mesh-C6Sp4Ysc.js";
|
|
10
10
|
import { i as buildBlockTints, n as BlockTintPack, t as BlockTint } from "./tints-2k3ZhkY3.js";
|
package/dist/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import { t as buildBlockTints } from "./tints-a9FWZLma.js";
|
|
|
10
10
|
import { o as createAtlasResolver, s as parseAtlasSources, t as AtlasSourceError } from "./sources-BlUriDCs.js";
|
|
11
11
|
import { n as LayeredResourceManager, r as ResourceKind, t as FolderResourceManager } from "./manager-CYbAkWuT.js";
|
|
12
12
|
import { n as TextureLoader, r as TextureResolutionError, t as AnimatedTexture } from "./loader-C18GpurU.js";
|
|
13
|
-
import { t as exportBlockPack } from "./export-
|
|
13
|
+
import { t as exportBlockPack } from "./export-BNvYiw6i.js";
|
|
14
14
|
import { a as defaultProperties, i as UNKNOWN_MODEL, n as InvalidItemDefinitionError, o as evaluateItemModel } from "./definition-ColsvWrH.js";
|
|
15
15
|
import { n as UnsafeJarError, r as isUnsafeEntryPath, t as JarResourceManager } from "./jar-5aLDI0nT.js";
|
|
16
16
|
import { n as prepareModResources } from "./prepare-B8oPdGYz.js";
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
import { a as FaceDirectionName, l as Vec3, o as ModelElementJson, u as Vec4 } from "./types-qlp3I8_-.js";
|
|
2
|
+
import { a as BlockStateMultipartCase, o as BlockStateVariantCase } from "./blockstate-eval-BzznRcVY.js";
|
|
3
|
+
import { t as MeshGroup } from "./obj-mesh-C6Sp4Ysc.js";
|
|
4
|
+
import { n as BlockTintPack } from "./tints-2k3ZhkY3.js";
|
|
5
|
+
//#region src/blocks/pack-format.d.ts
|
|
6
|
+
/** How a sprite's alpha classifies it, inferred because assets rarely say. */
|
|
7
|
+
type BlockPackRenderLayer = 'solid' | 'cutout' | 'translucent';
|
|
8
|
+
interface BlockPackFace {
|
|
9
|
+
sprite: string;
|
|
10
|
+
/** [u1, v1, u2, v2] in 0–16 sprite space, derived when the model omits it. */
|
|
11
|
+
uv: Vec4;
|
|
12
|
+
rotation?: number;
|
|
13
|
+
tintindex?: number;
|
|
14
|
+
cullface?: FaceDirectionName;
|
|
15
|
+
}
|
|
16
|
+
interface BlockPackElement {
|
|
17
|
+
from: Vec3;
|
|
18
|
+
to: Vec3;
|
|
19
|
+
rotation?: ModelElementJson['rotation'];
|
|
20
|
+
shade?: false;
|
|
21
|
+
faces: Partial<Record<FaceDirectionName, BlockPackFace>>;
|
|
22
|
+
}
|
|
23
|
+
interface BlockPackModel {
|
|
24
|
+
ao: boolean;
|
|
25
|
+
elements: BlockPackElement[];
|
|
26
|
+
/**
|
|
27
|
+
* The model's `particle` texture. What the game throws when the block breaks
|
|
28
|
+
* or is walked on, and the only colour a consumer has to work with for a
|
|
29
|
+
* block that draws nothing — a placeholder cube for a chest comes out oak
|
|
30
|
+
* rather than magenta.
|
|
31
|
+
*/
|
|
32
|
+
particle?: string;
|
|
33
|
+
/** Triangle geometry from an OBJ loader, when the model uses one. */
|
|
34
|
+
mesh?: MeshGroup[];
|
|
35
|
+
/**
|
|
36
|
+
* The layer the model states it draws on. Authoritative where present, and
|
|
37
|
+
* it beats the per-sprite alpha inference — the same sprite can be solid in
|
|
38
|
+
* one model and translucent in another.
|
|
39
|
+
*/
|
|
40
|
+
renderType?: BlockPackRenderLayer;
|
|
41
|
+
/** Block offsets a split-multiblock mesh spans. */
|
|
42
|
+
multiblock?: Array<[number, number, number]>;
|
|
43
|
+
/**
|
|
44
|
+
* Present when the block is a fluid, whose real surface height and flow
|
|
45
|
+
* direction come from its neighbours and so cannot be baked. The cube here is
|
|
46
|
+
* a stand-in; these are the sheets to mesh the real thing with.
|
|
47
|
+
*/
|
|
48
|
+
fluid?: {
|
|
49
|
+
still: string;
|
|
50
|
+
flow: string;
|
|
51
|
+
overlay?: string;
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
interface BlockPackSpriteFrame {
|
|
55
|
+
page: number;
|
|
56
|
+
x: number;
|
|
57
|
+
y: number;
|
|
58
|
+
/** Duration in game ticks. */
|
|
59
|
+
time: number;
|
|
60
|
+
}
|
|
61
|
+
interface BlockPackSprite {
|
|
62
|
+
page: number;
|
|
63
|
+
x: number;
|
|
64
|
+
y: number;
|
|
65
|
+
w: number;
|
|
66
|
+
h: number;
|
|
67
|
+
layer: BlockPackRenderLayer;
|
|
68
|
+
/** The displayed sequence, which can revisit a frame; absent when static. */
|
|
69
|
+
frames?: BlockPackSpriteFrame[];
|
|
70
|
+
interpolate?: true;
|
|
71
|
+
}
|
|
72
|
+
interface BlockPackAtlasPage {
|
|
73
|
+
file: string;
|
|
74
|
+
width: number;
|
|
75
|
+
height: number;
|
|
76
|
+
}
|
|
77
|
+
/** `atlas.json`. */
|
|
78
|
+
interface BlockPackAtlasFile {
|
|
79
|
+
/** Edge-extended border per sprite, in pixels. */
|
|
80
|
+
padding: number;
|
|
81
|
+
pages: BlockPackAtlasPage[];
|
|
82
|
+
sprites: Record<string, BlockPackSprite>;
|
|
83
|
+
}
|
|
84
|
+
/** `models.json`, by fully-qualified model id. */
|
|
85
|
+
type BlockPackModelsFile = Record<string, BlockPackModel>;
|
|
86
|
+
/** `blockstates.json`, by block id, with keys and predicates already parsed. */
|
|
87
|
+
type BlockPackBlockStatesFile = Record<string, BlockPackBlockState>;
|
|
88
|
+
/**
|
|
89
|
+
* A variant as the pack writes it. Every rotation is optional because the emit
|
|
90
|
+
* drops each one at its default, which is most of them.
|
|
91
|
+
*/
|
|
92
|
+
interface BlockPackVariant {
|
|
93
|
+
model: string;
|
|
94
|
+
x?: number;
|
|
95
|
+
y?: number;
|
|
96
|
+
z?: number;
|
|
97
|
+
uvlock?: true;
|
|
98
|
+
weight?: number;
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* One block's cases as the pack writes them: what `evaluateBlockState` takes,
|
|
102
|
+
* flattened to the key the file uses. Pass it as
|
|
103
|
+
* `{ kind: 'variants', cases: state.variants }` and the models come back as
|
|
104
|
+
* `BlockPackVariant`, no cast in either direction.
|
|
105
|
+
*/
|
|
106
|
+
type BlockPackBlockState = {
|
|
107
|
+
variants: Array<BlockStateVariantCase<BlockPackVariant>>;
|
|
108
|
+
multipart?: undefined;
|
|
109
|
+
} | {
|
|
110
|
+
multipart: Array<BlockStateMultipartCase<BlockPackVariant>>;
|
|
111
|
+
variants?: undefined;
|
|
112
|
+
};
|
|
113
|
+
/** `tints.json`. */
|
|
114
|
+
type BlockPackTintsFile = BlockTintPack;
|
|
115
|
+
/** `meta.json`, written last because it hashes every other file. */
|
|
116
|
+
interface BlockPackMetaFile {
|
|
117
|
+
generator: string;
|
|
118
|
+
version: string;
|
|
119
|
+
namespaces: string[];
|
|
120
|
+
counts: {
|
|
121
|
+
blocks: number;
|
|
122
|
+
models: number;
|
|
123
|
+
sprites: number;
|
|
124
|
+
pages: number;
|
|
125
|
+
failures: number;
|
|
126
|
+
};
|
|
127
|
+
/** sha256 per file, enough to verify a cached copy without refetching it. */
|
|
128
|
+
hashes: Record<string, string>;
|
|
129
|
+
}
|
|
130
|
+
//#endregion
|
|
131
|
+
export { BlockPackElement as a, BlockPackModel as c, BlockPackSprite as d, BlockPackSpriteFrame as f, BlockPackBlockStatesFile as i, BlockPackModelsFile as l, BlockPackVariant as m, BlockPackAtlasPage as n, BlockPackFace as o, BlockPackTintsFile as p, BlockPackBlockState as r, BlockPackMetaFile as s, BlockPackAtlasFile as t, BlockPackRenderLayer as u };
|
package/dist/pack.d.ts
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { a as BlockStateMultipartCase, d as matchesCondition, n as BlockProperties, o as BlockStateVariantCase, p as weightedVariantIndex, r as BlockStateDefinition, s as MultipartCondition, t as BlockModelVariant, u as evaluateBlockState } from "./blockstate-eval-BzznRcVY.js";
|
|
2
|
+
import { n as ObjMesh, t as MeshGroup } from "./obj-mesh-C6Sp4Ysc.js";
|
|
3
|
+
import { n as BlockTintPack, t as BlockTint } from "./tints-2k3ZhkY3.js";
|
|
4
|
+
import { a as BlockPackElement, c as BlockPackModel, d as BlockPackSprite, f as BlockPackSpriteFrame, i as BlockPackBlockStatesFile, l as BlockPackModelsFile, m as BlockPackVariant, n as BlockPackAtlasPage, o as BlockPackFace, p as BlockPackTintsFile, r as BlockPackBlockState, s as BlockPackMetaFile, t as BlockPackAtlasFile, u as BlockPackRenderLayer } from "./pack-format-CfCP4kzy.js";
|
|
5
|
+
export { type BlockModelVariant, type BlockPackAtlasFile, type BlockPackAtlasPage, type BlockPackBlockState, type BlockPackBlockStatesFile, type BlockPackElement, type BlockPackFace, type BlockPackMetaFile, type BlockPackModel, type BlockPackModelsFile, type BlockPackRenderLayer, type BlockPackSprite, type BlockPackSpriteFrame, type BlockPackTintsFile, type BlockPackVariant, type BlockProperties, type BlockStateDefinition, type BlockStateMultipartCase, type BlockStateVariantCase, type BlockTint, type BlockTintPack, type MeshGroup, type MultipartCondition, type ObjMesh, evaluateBlockState, matchesCondition, weightedVariantIndex };
|
package/dist/pack.js
ADDED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nodecraft/rendermite",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.3.1",
|
|
4
4
|
"description": "Minecraft item icon renderer: renders inventory-identical item icons from vanilla and modded assets across game versions, outputting optimized PNG/WebP/AVIF plus CSS and a JSON item library.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -28,6 +28,10 @@
|
|
|
28
28
|
".": {
|
|
29
29
|
"types": "./dist/index.d.ts",
|
|
30
30
|
"import": "./dist/index.js"
|
|
31
|
+
},
|
|
32
|
+
"./pack": {
|
|
33
|
+
"types": "./dist/pack.d.ts",
|
|
34
|
+
"import": "./dist/pack.js"
|
|
31
35
|
}
|
|
32
36
|
},
|
|
33
37
|
"files": [
|
|
@@ -65,6 +69,7 @@
|
|
|
65
69
|
"@types/yazl": "3.3.1",
|
|
66
70
|
"eslint": "10.8.0",
|
|
67
71
|
"rimraf": "6.1.3",
|
|
72
|
+
"rolldown": "1.2.3",
|
|
68
73
|
"semantic-release": "25.0.9",
|
|
69
74
|
"tsdown": "0.22.14",
|
|
70
75
|
"typescript": "6.0.3",
|