diff --git a/_test/all.meta.json b/_test/all.meta.json index d8a84a1..dd97684 100644 --- a/_test/all.meta.json +++ b/_test/all.meta.json @@ -1 +1 @@ -{"buildNum":"cdda-experimental-2024-10-11-2346","sha":"52f61be10adac5acec6ad08dd0ba4cdc9f04025a1ca02dc453321fbdaabea527"} \ No newline at end of file +{"buildNum":"cdda-experimental-2024-10-25-0415","sha":"5ff456238aa00ae8552bcf29190e30ff2341bad0bd5f7c4fc2b71d120762601f"} \ No newline at end of file diff --git a/src/types.ts b/src/types.ts index 90fd12f..8f8689c 100644 --- a/src/types.ts +++ b/src/types.ts @@ -1650,7 +1650,7 @@ export type OvermapTerrain = { name: Translation; sym?: string; // defaults to \u00a0 - color: string; + color?: string; // ... }; diff --git a/src/types/item/OvermapAppearance.svelte b/src/types/item/OvermapAppearance.svelte index b0abb0f..390662b 100644 --- a/src/types/item/OvermapAppearance.svelte +++ b/src/types/item/OvermapAppearance.svelte @@ -84,7 +84,7 @@ function omtAppearance( const omt = data.byIdMaybe("overmap_terrain", omt_id); return omt ? { - color: omt.color, + color: omt.color ?? "black", sym: rotateSymbol(omt.sym ?? "\u00a0" /* LINE_XOXO_C */, dir), name: singular(omt.name), } diff --git a/src/types/item/spawnLocations.ts b/src/types/item/spawnLocations.ts index 7478868..45e296d 100644 --- a/src/types/item/spawnLocations.ts +++ b/src/types/item/spawnLocations.ts @@ -333,7 +333,7 @@ export function overmapAppearance( function omtAppearanceString(omt_id: string): string { const omt = data.byId("overmap_terrain", omt_id); return omt - ? `${omt.sym}\u0001${omt.color}\u0001${omt.name}` + ? `${omt.sym}\u0001${omt.color ?? "black"}\u0001${omt.name}` : `appearance_unk`; } }