From 2f4f66cd644d08fc6001a07554f1049db300abd0 Mon Sep 17 00:00:00 2001 From: Kieran Farr Date: Mon, 9 Dec 2024 14:01:02 -0800 Subject: [PATCH] intersection children not clickable --- src/components/intersection.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/components/intersection.js b/src/components/intersection.js index df7d6874..566af60c 100644 --- a/src/components/intersection.js +++ b/src/components/intersection.js @@ -82,6 +82,7 @@ AFRAME.registerComponent('intersection', { ); sd.setAttribute('data-layer-name', 'Sidewalk • ' + displayName); sd.setAttribute('data-no-transform', ''); + sd.setAttribute('data-ignore-raycaster', ''); el.appendChild(sd); } @@ -239,6 +240,7 @@ AFRAME.registerComponent('intersection', { stopSignEl.classList.add('autocreated'); stopSignEl.setAttribute('data-layer-name', 'Traffic Control • Stop Sign'); stopSignEl.setAttribute('data-no-transform'); + stopSignEl.setAttribute('data-ignore-raycaster'); return stopSignEl; } @@ -334,6 +336,7 @@ AFRAME.registerComponent('intersection', { trafficSignalEl.setAttribute('rotation', params[side].rotation); trafficSignalEl.setAttribute('mixin', `signal_${side}`); trafficSignalEl.setAttribute('data-no-transform', ''); + trafficSignalEl.setAttribute('data-ignore-raycaster', ''); trafficSignalEl.classList.add('autocreated'); trafficSignalEl.setAttribute( 'data-layer-name', @@ -358,6 +361,7 @@ AFRAME.registerComponent('intersection', { cw1.setAttribute('mixin', 'markings crosswalk-zebra'); cw1.setAttribute('data-layer-name', 'Crosswalk • West'); cw1.setAttribute('data-no-transform', ''); + cw1.setAttribute('data-ignore-raycaster', ''); cw1.classList.add('autocreated'); el.appendChild(cw1); } @@ -369,6 +373,7 @@ AFRAME.registerComponent('intersection', { cw2.setAttribute('mixin', 'markings crosswalk-zebra'); cw2.setAttribute('data-layer-name', 'Crosswalk • East'); cw2.setAttribute('data-no-transform', ''); + cw2.setAttribute('data-ignore-raycaster', ''); cw2.classList.add('autocreated'); el.appendChild(cw2); } @@ -380,6 +385,7 @@ AFRAME.registerComponent('intersection', { cw3.setAttribute('mixin', 'markings crosswalk-zebra'); cw3.setAttribute('data-layer-name', 'Crosswalk • North'); cw3.setAttribute('data-no-transform', ''); + cw3.setAttribute('data-ignore-raycaster', ''); cw3.classList.add('autocreated'); el.appendChild(cw3); } @@ -388,6 +394,7 @@ AFRAME.registerComponent('intersection', { cw4.setAttribute('position', { y: -intersectDepth / 2 + 2, z: 0.11 }); cw4.setAttribute('data-layer-name', 'Crosswalk • South'); cw4.setAttribute('data-no-transform', ''); + cw4.setAttribute('data-ignore-raycaster', ''); cw4.setAttribute('rotation', { x: 0, y: 0, z: 90 }); cw4.setAttribute('scale', { y: intersectWidth / 12 }); cw4.setAttribute('mixin', 'markings crosswalk-zebra');