@ -34,7 +34,7 @@ setTimeout( _ => {
let positions = [ "-1 1 -3.5", "-1 2 -3.5", "0 0 -3.5", "0 1 -3.5", "1 0 -3.5", "-1 0 -3.5" ]
// triangle example, could be based on room boundaries instead
positions.map( pos => { addFromTemplate(pos, rot, scaffoldingInnerHTMLTemplate) })
}, 2 000)
}, 9 000)
function addFromTemplate(pos="0 0 0", rot="0 0 0", template="< a-box > < / a-box > "){
let el = document.createElement("a-entity")
@ -97,8 +97,14 @@ AFRAME.registerComponent('scaffolding', {
< / div >
< a-scene startfunctions onemptypinch = "onHoveredTeleport()" >
< a-gltf-model hide-on-enter-ar = "" id = "environment" src = "../content/CubeRoom.glb" rotation = "0 -90 0" position = "0 0 1" scale = "" > < / a-gltf-model >
<!-- Cube Room by Anonymous [CC - BY] via Poly Pizza -->
< a-assets >
< video id = "dolomites1_preview" src = "/pub/home/360s/Dolomites2024Videos/R0012604_preview.MP4" > < / video >
< video id = "dolomites1" autoplay src = "/pub/home/360s/Dolomites2024Videos/R0012604.MP4" > < / video >
< video id = "dolomites2" autoplay src = "/pub/home/360s/Dolomites2024Videos/R0012610.MP4" > < / video >
< / a-assets >
< a-videosphere src = "#dolomites2" > < / a-videosphere >
< a-entity id = "rig" >
< a-entity id = "player" networked = "template:#avatar-template;attachTemplateToLocal:false;"
@ -118,7 +124,6 @@ AFRAME.registerComponent('scaffolding', {
< a-troika-text value = "SpaSca : Spatial Scaffolding" anchor = "left" outline-width = "5%" font = "../content/ChakraPetch-Regular.ttf" position = "-3 5 -2"
scale="3 3 3" rotation="80 0 0" troika-text="outlineWidth: 0.01; strokeColor: #ffffff" material="flatShading: true; blending: additive; emissive: #c061cb">< / a-troika-text >
< a-sky hide-on-enter-ar color = "lightgray" > < / a-sky >
< a-troika-text anchor = left target value = "instructions : \n--right pinch to move\n--left pinch to execute" position = "0 0.65 -0.2" scale = "0.1 0.1 0.1" > < / a-troika-text >
< a-troika-text anchor = left value = "jxr location.reload()" target position = " -0.3 1.30 0" rotation = "0 40 0" scale = "0.1 0.1 0.1" > < / a-troika-text >
@ -136,6 +141,9 @@ Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliqu
< a-troika-text anchor = left line-height = "1" value = "Lorem ipsum dolor sit amet , consectetur adipiscing elit , sed do eiusmod tempor incididunt ut labore et dolore magna aliqua .
Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. " target position="0.5 .85 0" rotation="0 -40 0" scale="0.1 0.1 0.1">< / a-troika-text >
< a-troika-text anchor = left value = "jxr document.querySelector('video').play()" target position = "-0.3 1.20 -.5" rotation = "0 0 0" scale = "0.1 0.1 0.1" > < / a-troika-text >
<!-- only plays audio, might need permission via user action, i.e a button -->
< / a-scene >
< / body >
< / script >