@nodecraft/rendermite 1.12.0 → 1.12.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/dist/cli.js +1 -1
- package/dist/dynamic/generators.d.ts +2 -2
- package/dist/dynamic/generators.js +1 -1
- package/dist/{generators-7b5w6s0L.js → generators-BkxWJuMK.js} +9 -1
- package/dist/{generators-P1goUyvI.d.ts → generators-CuFVs1hg.d.ts} +7 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +2 -2
- package/dist/{item-styles-D-7N6j1i.js → item-styles-K4XuYZ_A.js} +1 -1
- package/dist/output/item-styles.js +1 -1
- package/dist/{pipeline-DV4hIRMp.js → pipeline-C73ceHEM.js} +1 -1
- package/dist/render/pipeline.js +1 -1
- package/dist/{run-5Rc8hTHT.js → run-CwQrEjp1.js} +4 -3
- package/dist/run.js +1 -1
- package/dist/workers/render-worker.js +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -7,7 +7,7 @@ import { t as curatedModelOverrides } from "./models-CvFehP26.js";
|
|
|
7
7
|
import { n as harvestTintOverrides, t as curatedTintOverrides } from "./tints-DhSA5SCg.js";
|
|
8
8
|
import { t as downloadClientJar } from "./download-1wAfrGKx.js";
|
|
9
9
|
import { t as runBlocksCli } from "./cli-CeEAmdX9.js";
|
|
10
|
-
import { t as run } from "./run-
|
|
10
|
+
import { t as run } from "./run-CwQrEjp1.js";
|
|
11
11
|
import path from "node:path";
|
|
12
12
|
import os from "node:os";
|
|
13
13
|
import { parseArgs } from "node:util";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as TRIM_DARKER_MATERIALS, i as POTTERY_SHERDS, n as DynamicItem, o as TRIM_MATERIALS, r as DynamicResources, s as builtinDynamicResources, t as ARMOR_ITEM_TYPES } from "../generators-
|
|
2
|
-
export { ARMOR_ITEM_TYPES, DynamicItem, DynamicResources, POTTERY_SHERDS, TRIM_DARKER_MATERIALS, TRIM_MATERIALS, builtinDynamicResources };
|
|
1
|
+
import { a as TRIM_DARKER_MATERIALS, c as hasArmorTrims, i as POTTERY_SHERDS, n as DynamicItem, o as TRIM_MATERIALS, r as DynamicResources, s as builtinDynamicResources, t as ARMOR_ITEM_TYPES } from "../generators-CuFVs1hg.js";
|
|
2
|
+
export { ARMOR_ITEM_TYPES, DynamicItem, DynamicResources, POTTERY_SHERDS, TRIM_DARKER_MATERIALS, TRIM_MATERIALS, builtinDynamicResources, hasArmorTrims };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as ARMOR_ITEM_TYPES, n as POTTERY_SHERDS, r as TRIM_DARKER_MATERIALS, i as TRIM_MATERIALS, a as builtinDynamicResources } from "../generators-
|
|
1
|
+
export { t as ARMOR_ITEM_TYPES, n as POTTERY_SHERDS, r as TRIM_DARKER_MATERIALS, i as TRIM_MATERIALS, a as builtinDynamicResources, o as hasArmorTrims } from "../generators-BkxWJuMK.js";
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { n as ResourceLocator } from "./locator-COMEtEn9.js";
|
|
1
2
|
import { n as MapResourceManager } from "./synthetic-y9Mr-wB2.js";
|
|
2
3
|
//#region src/dynamic/generators.ts
|
|
3
4
|
/**
|
|
@@ -64,6 +65,13 @@ function sherdTextureName(sherd) {
|
|
|
64
65
|
return sherd === "brick" ? "brick" : `${sherd}_pottery_sherd`;
|
|
65
66
|
}
|
|
66
67
|
/**
|
|
68
|
+
* Whether the version has armor trims, judged by the trim palette key: 26.3 moved it from
|
|
69
|
+
* textures/trims/color_palettes/trim_palette to textures/palettes/trim_base.
|
|
70
|
+
*/
|
|
71
|
+
async function hasArmorTrims(resources) {
|
|
72
|
+
return await resources.hasResource("texture", ResourceLocator.parse("minecraft:trims/color_palettes/trim_palette")) || await resources.hasResource("texture", ResourceLocator.parse("minecraft:palettes/trim_base"));
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
67
75
|
* Materials whose trim sprites exist for the target version are discovered by
|
|
68
76
|
* the caller (via the atlas resolver); this generates the full matrix and lets
|
|
69
77
|
* missing sprites fail per item.
|
|
@@ -143,4 +151,4 @@ function builtinDynamicResources() {
|
|
|
143
151
|
};
|
|
144
152
|
}
|
|
145
153
|
//#endregion
|
|
146
|
-
export { builtinDynamicResources as a, TRIM_MATERIALS as i, POTTERY_SHERDS as n, TRIM_DARKER_MATERIALS as r, ARMOR_ITEM_TYPES as t };
|
|
154
|
+
export { builtinDynamicResources as a, TRIM_MATERIALS as i, POTTERY_SHERDS as n, hasArmorTrims as o, TRIM_DARKER_MATERIALS as r, ARMOR_ITEM_TYPES as t };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { a as ResourceManager } from "./manager-Ey26G_3e.js";
|
|
1
2
|
import { n as MapResourceManager } from "./synthetic-C8_0G5iP.js";
|
|
2
3
|
//#region src/dynamic/generators.d.ts
|
|
3
4
|
declare const TRIM_MATERIALS: readonly ["quartz", "iron", "gold", "diamond", "netherite", "redstone", "copper", "emerald", "lapis", "amethyst", "resin"];
|
|
@@ -5,6 +6,11 @@ declare const TRIM_MATERIALS: readonly ["quartz", "iron", "gold", "diamond", "ne
|
|
|
5
6
|
declare const TRIM_DARKER_MATERIALS: Set<string>;
|
|
6
7
|
declare const ARMOR_ITEM_TYPES: readonly ["boots", "leggings", "chestplate", "helmet"];
|
|
7
8
|
declare const POTTERY_SHERDS: readonly ["brick", "angler", "archer", "arms_up", "blade", "brewer", "burn", "danger", "explorer", "friend", "heart", "heartbreak", "howl", "miner", "mourner", "plenty", "prize", "sheaf", "shelter", "skull", "snort", "flow", "guster", "scrape"];
|
|
9
|
+
/**
|
|
10
|
+
* Whether the version has armor trims, judged by the trim palette key: 26.3 moved it from
|
|
11
|
+
* textures/trims/color_palettes/trim_palette to textures/palettes/trim_base.
|
|
12
|
+
*/
|
|
13
|
+
declare function hasArmorTrims(resources: ResourceManager): Promise<boolean>;
|
|
8
14
|
interface DynamicItem {
|
|
9
15
|
/** Item id including the synthetic namespace, e.g. `_armor_trims:helmet_trim_gold`. */
|
|
10
16
|
id: string;
|
|
@@ -20,4 +26,4 @@ interface DynamicResources {
|
|
|
20
26
|
*/
|
|
21
27
|
declare function builtinDynamicResources(): DynamicResources;
|
|
22
28
|
//#endregion
|
|
23
|
-
export { TRIM_DARKER_MATERIALS as a, POTTERY_SHERDS as i, DynamicItem as n, TRIM_MATERIALS as o, DynamicResources as r, builtinDynamicResources as s, ARMOR_ITEM_TYPES as t };
|
|
29
|
+
export { TRIM_DARKER_MATERIALS as a, hasArmorTrims as c, POTTERY_SHERDS as i, DynamicItem as n, TRIM_MATERIALS as o, DynamicResources as r, builtinDynamicResources as s, ARMOR_ITEM_TYPES as t };
|
package/dist/index.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ import { a as resolveTexture, n as ModelResolutionError, o as salvageJson, r as
|
|
|
9
9
|
import { i as buildObjMesh, n as ObjMesh, r as ObjMeshError, t as MeshGroup } from "./obj-mesh-yN3ttPYf.js";
|
|
10
10
|
import { a as buildBlockTints, i as UNREGISTERED_TINTS, n as BlockTintPack, t as BlockTint } from "./tints-CvHlfvDC.js";
|
|
11
11
|
import { i as exportBlockPack, n as BlockPackResult, r as ExportBlockPackOptions, t as BlockPackFailure } from "./export-BL_3VVZI.js";
|
|
12
|
-
import { s as builtinDynamicResources } from "./generators-
|
|
12
|
+
import { s as builtinDynamicResources } from "./generators-CuFVs1hg.js";
|
|
13
13
|
import { d as toFloatTexture, n as FloatTexture, u as toByteTexture } from "./blend-DnogOnaU.js";
|
|
14
14
|
import { a as LightingProfileName, i as LightingProfile, r as LightSource, u as lightsForProfile } from "./lighting-DYkS-NlV.js";
|
|
15
15
|
import { a as RenderedFrames, c as renderModel, i as RenderOptions, l as renderModelFrames, o as boxDownscale, r as ItemRenderError, s as pointResize } from "./renderer-DZSDiXL0.js";
|
package/dist/index.js
CHANGED
|
@@ -18,9 +18,9 @@ import { o as createAtlasResolver, s as parseAtlasSources, t as AtlasSourceError
|
|
|
18
18
|
import { n as TextureLoader, r as TextureResolutionError, t as AnimatedTexture } from "./loader-CsgtBuBo.js";
|
|
19
19
|
import { t as exportBlockPack } from "./export-BPH-b4LT.js";
|
|
20
20
|
import { n as prepareModResources } from "./prepare-DJnJQYtn.js";
|
|
21
|
+
import { a as builtinDynamicResources } from "./generators-BkxWJuMK.js";
|
|
21
22
|
import { n as encodeIcon, t as encodeAnimatedIcon } from "./encode-BIAWeZy2.js";
|
|
22
|
-
import { a as builtinDynamicResources } from "./generators-7b5w6s0L.js";
|
|
23
23
|
import { t as minifyStylesheet } from "./minify-bjMRmr5J.js";
|
|
24
24
|
import { n as itemClass, t as generateStylesheet } from "./stylesheet-Cin7eCyU.js";
|
|
25
|
-
import { t as run } from "./run-
|
|
25
|
+
import { t as run } from "./run-CwQrEjp1.js";
|
|
26
26
|
export { AnimatedTexture, AtlasSourceError, BlockStateError, DEFAULT_WATER_COLOR, DYE_COLORS, FolderResourceManager, InvalidItemDefinitionError, InvalidResourceLocatorError, InvalidTinterDefinitionError, ItemRenderError, ItemResolutionError, JarResourceManager, LEGACY_BIOMES, LayeredResourceManager, LightingProfile, ModelLoader, ModelResolutionError, ObjMeshError, PRE_JAR_BIOMES, ResourceKind, ResourceLocator, TextureLoader, TextureResolutionError, UNKNOWN_MODEL, UNREGISTERED_TINTS, UnsafeJarError, VANILLA_BIOME_CLIMATES, boxDownscale, buildBiomeClimates, buildBlockTints, buildObjMesh, builtinDynamicResources, collectModels, compareVersions, createAtlasResolver, defaultProperties, discoverItems, encodeAnimatedIcon, encodeIcon, eraForVersion, evaluateBlockState, evaluateItemModel, exportBlockPack, generateStylesheet, isUnsafeEntryPath, itemClass, lightsForProfile, matchesCondition, minifyStylesheet, packAtlas, parseAtlasSources, parseBiomeClimate, parseBlockState, parseTintValue, pointResize, prepareModResources, prepareVersionResources, renderModel, renderModelFrames, resolveItem, resolveTexture, resolveTint, resolveTints, run, salvageJson, toByteTexture, toFloatTexture, vanillaBiomesFor, weightedVariantIndex };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as TRIM_MATERIALS, n as POTTERY_SHERDS, r as TRIM_DARKER_MATERIALS, t as ARMOR_ITEM_TYPES } from "./generators-
|
|
1
|
+
import { i as TRIM_MATERIALS, n as POTTERY_SHERDS, r as TRIM_DARKER_MATERIALS, t as ARMOR_ITEM_TYPES } from "./generators-BkxWJuMK.js";
|
|
2
2
|
//#region src/output/item-styles.ts
|
|
3
3
|
/**
|
|
4
4
|
* Per-item CSS style classification, ported from upstream's ItemStyleGenerators
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as classifyItemStyle } from "../item-styles-
|
|
1
|
+
export { t as classifyItemStyle } from "../item-styles-K4XuYZ_A.js";
|
|
@@ -10,8 +10,8 @@ import { a as resolveTints } from "./tints-Cw5okshA.js";
|
|
|
10
10
|
import { t as loadAtlasResolver } from "./registry-CNFi94eo.js";
|
|
11
11
|
import { t as CachedListingResourceManager } from "./cached-BOX3n1Dl.js";
|
|
12
12
|
import { n as TextureLoader } from "./loader-CsgtBuBo.js";
|
|
13
|
+
import { a as builtinDynamicResources } from "./generators-BkxWJuMK.js";
|
|
13
14
|
import { t as encodeAnimatedIcon } from "./encode-BIAWeZy2.js";
|
|
14
|
-
import { a as builtinDynamicResources } from "./generators-7b5w6s0L.js";
|
|
15
15
|
import { a as spawnEggTints, i as renderEntityFallback, n as dyedVariantTint, r as renderDyedVariantFallback, t as dyeVariantName } from "./entity-fallback-ZfurtmEQ.js";
|
|
16
16
|
import { t as legacyTintsForChain } from "./legacy-tints-l-541wgI.js";
|
|
17
17
|
import { n as defaultBlockStateModel, t as blockStateTransform } from "./blockstate-D5FgI-Qv.js";
|
package/dist/render/pipeline.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { t as ItemPipeline } from "../pipeline-
|
|
1
|
+
export { t as ItemPipeline } from "../pipeline-C73ceHEM.js";
|
|
@@ -2,11 +2,12 @@ import { n as ResourceLocator } from "./locator-COMEtEn9.js";
|
|
|
2
2
|
import { n as LayeredResourceManager } from "./manager-B1VPl4UQ.js";
|
|
3
3
|
import { n as discoverItems } from "./discovery-CMHJfdHQ.js";
|
|
4
4
|
import { t as curatedModelOverrides } from "./models-CvFehP26.js";
|
|
5
|
+
import { o as hasArmorTrims } from "./generators-BkxWJuMK.js";
|
|
5
6
|
import { r as encodeRasterAsset } from "./encode-BIAWeZy2.js";
|
|
6
|
-
import { t as classifyItemStyle } from "./item-styles-
|
|
7
|
+
import { t as classifyItemStyle } from "./item-styles-K4XuYZ_A.js";
|
|
7
8
|
import { t as minifyStylesheet } from "./minify-bjMRmr5J.js";
|
|
8
9
|
import { t as generateStylesheet } from "./stylesheet-Cin7eCyU.js";
|
|
9
|
-
import { t as ItemPipeline } from "./pipeline-
|
|
10
|
+
import { t as ItemPipeline } from "./pipeline-C73ceHEM.js";
|
|
10
11
|
import { t as describeResources } from "./descriptor-CJLtRmBc.js";
|
|
11
12
|
import { t as WorkerRenderPool } from "./pool-Co7kPWwN.js";
|
|
12
13
|
import path from "node:path";
|
|
@@ -80,7 +81,7 @@ async function run(options) {
|
|
|
80
81
|
ids.push(item.id);
|
|
81
82
|
}
|
|
82
83
|
if (pipeline.dynamicItems && namespaces.includes("minecraft")) {
|
|
83
|
-
const hasTrims = await resources
|
|
84
|
+
const hasTrims = await hasArmorTrims(resources);
|
|
84
85
|
const groupAvailable = {
|
|
85
86
|
_armor_trims: hasTrims,
|
|
86
87
|
_leather_armor: hasTrims,
|
package/dist/run.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as ItemPipeline } from "../pipeline-
|
|
1
|
+
import { t as ItemPipeline } from "../pipeline-C73ceHEM.js";
|
|
2
2
|
import { n as restoreResources } from "../descriptor-CJLtRmBc.js";
|
|
3
3
|
import sharp from "sharp";
|
|
4
4
|
import { parentPort, workerData } from "node:worker_threads";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nodecraft/rendermite",
|
|
3
|
-
"version": "1.12.
|
|
3
|
+
"version": "1.12.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",
|