feat: include size 32 (catalog icon) sprites in nitro bundles
The SWF-to-Nitro converter previously dropped the size 32 visualization and any sprite image whose name contained '_32_', so bundles lacked the small/catalog render size. Keep them so each furniture bundle renders correctly at every scale the client requests. - xml-processor: stop skipping visualization size === 32 - index.ts: stop excluding '_32_' sprite assets/images from the sheet
This commit is contained in:
1 parent
53db4a858b
commit
2996ae3ab0
2 files changed
+6
-10
No files matched your search
@@ -203,12 +203,7 @@ export function convertSwfToNitro(
|
||||
: findChild(assetsRoot, "assets") || assetsRoot;
|
||||
for (const asset of findChildren(assetsNode, "asset")) {
|
||||
const assetName = asset.attrs.name || "";
|
||||
if (
|
||||
!assetName ||
|
||||
assetName.startsWith("sh_") ||
|
||||
assetName.includes("_32_")
|
||||
)
|
||||
continue;
|
||||
if (!assetName || assetName.startsWith("sh_")) continue;
|
||||
if (!asset.attrs.source) {
|
||||
neededSprites.add(assetName);
|
||||
} else {
|
||||
@@ -225,7 +220,7 @@ export function convertSwfToNitro(
|
||||
if (!rawName) continue;
|
||||
const name = stripPrefix(rawName);
|
||||
|
||||
if (name.startsWith("sh_") || name.includes("_32_")) continue;
|
||||
if (name.startsWith("sh_")) continue;
|
||||
if (neededSprites.size > 0 && !neededSprites.has(name)) continue;
|
||||
|
||||
namedImages.push({
|
||||
@@ -290,7 +285,7 @@ export function convertSwfToNitro(
|
||||
for (const asset of findChildren(assetsNode, "asset")) {
|
||||
const assetName = asset.attrs.name || "";
|
||||
if (!assetName) continue;
|
||||
if (assetName.startsWith("sh_") || assetName.includes("_32_")) continue;
|
||||
if (assetName.startsWith("sh_")) continue;
|
||||
|
||||
const x = parseInt(asset.attrs.x || "0", 10);
|
||||
const y = parseInt(asset.attrs.y || "0", 10);
|
||||
|
||||
Reference in new issue
Block a user