完善联调标准化与诊断链路
This commit is contained in:
@@ -68,6 +68,7 @@ export interface RemoteMapConfig {
|
||||
configAppId: string
|
||||
configSchemaVersion: string
|
||||
configVersion: string
|
||||
playfieldKind: string
|
||||
tileSource: string
|
||||
minZoom: number
|
||||
maxZoom: number
|
||||
@@ -122,6 +123,7 @@ interface ParsedGameConfig {
|
||||
appId: string
|
||||
schemaVersion: string
|
||||
version: string
|
||||
playfieldKind: string
|
||||
mapRoot: string
|
||||
mapMeta: string
|
||||
course: string | null
|
||||
@@ -1754,6 +1756,7 @@ function parseGameConfigFromJson(text: string, gameConfigUrl: string): ParsedGam
|
||||
appId: rawApp && typeof rawApp.id === 'string' ? rawApp.id : '',
|
||||
schemaVersion: typeof parsed.schemaVersion === 'string' ? parsed.schemaVersion : '1',
|
||||
version: typeof parsed.version === 'string' ? parsed.version : '',
|
||||
playfieldKind: rawPlayfield && typeof rawPlayfield.kind === 'string' ? rawPlayfield.kind : '',
|
||||
mapRoot,
|
||||
mapMeta,
|
||||
course: rawPlayfieldSource && typeof rawPlayfieldSource.url === 'string'
|
||||
@@ -1855,6 +1858,7 @@ function parseGameConfigFromYaml(text: string, gameConfigUrl: string): ParsedGam
|
||||
appId: '',
|
||||
schemaVersion: '1',
|
||||
version: '',
|
||||
playfieldKind: typeof config.playfieldkind === 'string' ? config.playfieldkind : '',
|
||||
mapRoot,
|
||||
mapMeta,
|
||||
course: typeof config.course === 'string' ? config.course : null,
|
||||
@@ -2157,6 +2161,7 @@ export async function loadRemoteMapConfig(gameConfigUrl: string): Promise<Remote
|
||||
configAppId: gameConfig.appId || '',
|
||||
configSchemaVersion: gameConfig.schemaVersion || '1',
|
||||
configVersion: gameConfig.version || '',
|
||||
playfieldKind: gameConfig.playfieldKind || '',
|
||||
tileSource: resolveUrl(mapRootUrl, mapMeta.tilePathTemplate),
|
||||
minZoom: mapMeta.minZoom,
|
||||
maxZoom: mapMeta.maxZoom,
|
||||
|
||||
Reference in New Issue
Block a user