This commit is contained in:
2026-04-22 20:14:15 +08:00
parent 0773a0d0ca
commit 0e9c286a57
205 changed files with 25790 additions and 1623 deletions

View File

@@ -51,6 +51,7 @@ import {
DEFAULT_PRIVATE_CHAT_UNLOCK_AFFINITY,
} from './affinityLevels';
import { coerceWorldAttributeSchema } from './attributeValidation';
import { normalizeCustomWorldSceneRelativePosition } from './customWorldSceneGraph';
import {
type CustomWorldLandmarkDraft,
normalizeCustomWorldLandmarks,
@@ -877,8 +878,11 @@ function normalizeCampScene(
connections: toRecordArray(value.connections)
.map((connection) => ({
targetLandmarkId: toText(connection.targetLandmarkId),
relativePosition:
toText(connection.relativePosition) || toText(connection.position) || 'forward',
relativePosition: normalizeCustomWorldSceneRelativePosition(
toText(connection.relativePosition) ||
toText(connection.position) ||
'forward',
),
summary: toText(connection.summary) || toText(connection.description),
}))
.filter((connection) => connection.targetLandmarkId),
@@ -920,8 +924,9 @@ function normalizeLandmarkDraft(
toText(connection.targetLandmarkName) ||
toText(connection.target) ||
toText(connection.sceneName),
relativePosition:
relativePosition: normalizeCustomWorldSceneRelativePosition(
toText(connection.relativePosition) || toText(connection.position),
),
summary: toText(connection.summary) || toText(connection.description),
})),
};