Skip to content

Commit c21d578

Browse files
authored
Merge pull request #32 from ir-engine/IR-5334
IR-5334
2 parents 6f0283e + 4c01e14 commit c21d578

File tree

3 files changed

+7
-38
lines changed

3 files changed

+7
-38
lines changed

resources.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
],
2323
"dependencies": [],
2424
"name": "Racer-transformed.gltf",
25-
"thumbnailKey": "https://172.27.136.37:8642/projects/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_Racer-transformed.gltf-thumbnail.png",
25+
"thumbnailKey": "__$project$__/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_Racer-transformed.gltf-thumbnail.png",
2626
"thumbnailMode": "automatic"
2727
},
2828
"assets/animations/Racer/740e60973cb1cb9852ebe8821bcaf77f2fda66b68f5ed2c143ef504087968238.bin": {
@@ -72,7 +72,7 @@
7272
],
7373
"dependencies": [],
7474
"name": "rings.glb",
75-
"thumbnailKey": "https://172.27.136.37:8642/projects/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_rings.glb-thumbnail.png",
75+
"thumbnailKey": "__$project$__/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_rings.glb-thumbnail.png",
7676
"thumbnailMode": "automatic"
7777
},
7878
"assets/animations/tornado-mobile-xr.glb": {
@@ -82,7 +82,7 @@
8282
],
8383
"dependencies": [],
8484
"name": "tornado-mobile-xr.glb",
85-
"thumbnailKey": "https://172.27.136.37:8642/projects/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_tornado-mobile-xr.glb-thumbnail.png",
85+
"thumbnailKey": "__$project$__/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_tornado-mobile-xr.glb-thumbnail.png",
8686
"thumbnailMode": "automatic"
8787
},
8888
"assets/animations/transforms.glb": {
@@ -92,7 +92,7 @@
9292
],
9393
"dependencies": [],
9494
"name": "transforms.glb",
95-
"thumbnailKey": "https://172.27.136.37:8642/projects/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_transforms.glb-thumbnail.png",
95+
"thumbnailKey": "__$project$__/ir-engine/ir-development-test-suite/public/thumbnails/assets_animations_transforms.glb-thumbnail.png",
9696
"thumbnailMode": "automatic"
9797
},
9898
"assets/envmaps/hall.glb": {

src/examples/WebXR.tsx

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/examples/multipleScenes.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ import {
4747
} from '@ir-engine/spatial/src/renderer/materials/MaterialComponent'
4848
// TransformComponent is already imported above
4949
import React, { useEffect } from 'react'
50-
import { Cache, Color, Euler, MathUtils, Matrix4, MeshLambertMaterial, Quaternion, Vector3 } from 'three'
50+
import { Color, Euler, MathUtils, Matrix4, MeshLambertMaterial, Quaternion, Vector3 } from 'three'
5151
import { Transform } from './utils/transform'
5252

5353
export const TestSuiteBallTagComponent = defineComponent({ name: 'TestSuiteBallTagComponent' })
@@ -166,10 +166,8 @@ const SceneReactor = (props: { coord: Vector3 }) => {
166166
const sceneID = `scene-${coord.x}-${coord.z}`
167167
const gltf = createSceneGLTF(sceneID)
168168

169-
const sceneURL = `/${sceneID}.gltf`
170-
171-
Cache.enabled = true
172-
Cache.add(sceneURL, gltf)
169+
const blob = new Blob([JSON.stringify(gltf)], { type: 'application/json' })
170+
const sceneURL = URL.createObjectURL(blob)
173171

174172
const gltfEntity = AssetState.load(sceneURL, sceneID as EntityID, Engine.instance.originEntity)
175173
getMutableComponent(Engine.instance.viewerEntity, RendererComponent).scenes.merge([gltfEntity])

0 commit comments

Comments
 (0)