File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
browser-interface/packages/shared/wearablesPortableExperience Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -121,8 +121,8 @@ function findWearableContent(wearable: WearableV2): [KeyAndHash[], KeyAndHash] |
121121export async function wearableToSceneEntity ( wearable : WearableV2 , defaultBaseUrl : string ) : Promise < LoadableScene > {
122122 const [ wearableContent , mainFile ] = findWearableContent ( wearable ) ?? [ ]
123123 if ( ! wearableContent ) throw new Error ( 'Invalid wearable' )
124- const defaultSceneJson = ( ) => ( {
125- main : mainFile ?. key ?? 'bin/game.js' ,
124+ const defaultSceneJson : ( ) => Scene = ( ) => ( {
125+ main : mainFile ?. key ? getFile ( mainFile ?. key ) : 'bin/game.js' ,
126126 scene : {
127127 parcels : [ '0,0' ] ,
128128 base : '0,0'
@@ -147,7 +147,7 @@ export async function wearableToSceneEntity(wearable: WearableV2, defaultBaseUrl
147147 }
148148
149149 const content = wearableContent . map ( ( $ ) => ( { file : getFile ( $ . key ) , hash : $ . hash } ) )
150- const metadata : Scene = sceneJson ? await jsonFetch ( baseUrl + sceneJson . hash ) : defaultSceneJson
150+ const metadata : Scene = sceneJson ? await jsonFetch ( baseUrl + sceneJson . hash ) : defaultSceneJson ( )
151151
152152 return {
153153 id : wearable . id ,
You can’t perform that action at this time.
0 commit comments