fix: use configured furni source and catalog assets
This commit is contained in:
1 parent
aed70db81f
commit
c78f8812ad
25 files changed
+368
-129
No files matched your search
@@ -18,7 +18,7 @@ import {
|
||||
IMPORTED_PAGE_CAPTION_SAVE,
|
||||
importSingleFurni,
|
||||
} from "@/lib/services/furni-import";
|
||||
import { getHabboItFurnidata } from "@/lib/services/habbo-furnidata-cache";
|
||||
import { getOfficialHabboFurnidata } from "@/lib/services/habbo-furnidata-cache";
|
||||
import { listFurniture } from "@/lib/services/habbofurni";
|
||||
import { rcon } from "@/lib/services/rcon";
|
||||
import { convertSwfToNitro } from "@/lib/services/swf-to-nitro";
|
||||
@@ -183,7 +183,7 @@ export const GET = withAdmin(
|
||||
const pageItems = missing.slice(start, start + perPage);
|
||||
|
||||
// Enrich with revision from official furnidata
|
||||
const furnidata = await getHabboItFurnidata();
|
||||
const furnidata = await getOfficialHabboFurnidata();
|
||||
const items = pageItems.map((item) => {
|
||||
const fd =
|
||||
furnidata.get(item.item_name) ||
|
||||
@@ -434,7 +434,7 @@ export const PATCH = withAdmin(
|
||||
// Resolve revision: try furnidata first, then spriteId as fallback
|
||||
let rev = item.revision || 0;
|
||||
if (rev === 0) {
|
||||
const furnidata = await getHabboItFurnidata();
|
||||
const furnidata = await getOfficialHabboFurnidata();
|
||||
const fd =
|
||||
furnidata.get(item.classname) ||
|
||||
furnidata.get(baseClassname) ||
|
||||
@@ -516,7 +516,7 @@ export const PATCH = withAdmin(
|
||||
.from(ItemsBase)
|
||||
.where(eq(ItemsBase.itemName, item.classname))
|
||||
.limit(1);
|
||||
const furnidata = await getHabboItFurnidata();
|
||||
const furnidata = await getOfficialHabboFurnidata();
|
||||
const fd =
|
||||
furnidata.get(item.classname) || furnidata.get(baseClassname);
|
||||
const itemType = dbItem?.type === "i" ? "i" : "s";
|
||||
@@ -531,7 +531,7 @@ export const PATCH = withAdmin(
|
||||
spriteId: dbItem?.spriteId || 0,
|
||||
dims: conversion.dimensions || { x: 1, y: 1, z: 1 },
|
||||
metadata: conversion.metadata || null,
|
||||
habboIt: fd || null,
|
||||
officialHabbo: fd || null,
|
||||
});
|
||||
await appendFurniEntry(entry, itemType);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user