Co-authored-by: Reifonas <211114984+Reifonas@users.noreply.github.com>
This commit is contained in:
gpt-engineer-app[bot]
2026-05-14 18:26:06 +00:00
parent 5035a0c6b4
commit 0eea73a3d2
+7 -2
View File
@@ -485,12 +485,15 @@ const XRSession = () => {
{effectiveInXR ? ( {effectiveInXR ? (
<> <>
{/* In XR (or SimXR): grab wrapper → ACTIVE model. Other models render as static background. */} {/* In XR (or SimXR): all models share the same placement origin so
<XRBackgroundModels /> switching active doesn't make others appear to "disappear".
Only the ACTIVE model receives grab transforms. */}
{simXR ? ( {simXR ? (
<group position={[0, 1.0, -1.2]}> <group position={[0, 1.0, -1.2]}>
<XRBackgroundModels />
<XRGrabbable <XRGrabbable
allowScale={allowScale} allowScale={allowScale}
lockedActive={isActiveLocked}
onGrabStart={() => { if (placementMode) setPlacementMode(false); }} onGrabStart={() => { if (placementMode) setPlacementMode(false); }}
> >
<XRActiveModel /> <XRActiveModel />
@@ -505,8 +508,10 @@ const XRSession = () => {
toast.success('Modelo posicionado na superfície!'); toast.success('Modelo posicionado na superfície!');
}} }}
> >
<XRBackgroundModels />
<XRGrabbable <XRGrabbable
allowScale={allowScale} allowScale={allowScale}
lockedActive={isActiveLocked}
onGrabStart={() => { if (placementMode) setPlacementMode(false); }} onGrabStart={() => { if (placementMode) setPlacementMode(false); }}
> >
<XRActiveModel /> <XRActiveModel />