Forum Widgets
Recent Discussions
VR Screen Navigation
Hi Team, I am struggling to perform screen navigation from a VR screen to another VR screen. I checked the samples but could not get any clue. Is it even supported or do we have to survive with loading different scenes in the launcher activity itself? Yes, I have added the activity in the manifest file and it works when I make that 2nd activity as launcher. However when I try to launch it from the 1st activity it simply crashes. This is the error I get ... FATAL EXCEPTION: main Process: com.mixed.reality.factory, PID: 26659 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.mixed.reality.factory/com.mixed.reality.factory.LoaderQuestActivity}: java.lang.Exception: Native Assert. FILE=icsHE/GraphicsHorizon.cpp:161 MSG= at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3807) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3947) at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103) at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:139) at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:96) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2468) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loopOnce(Looper.java:218) at android.os.Looper.loop(Looper.java:310) at android.app.ActivityThread.main(ActivityThread.java:8250) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:978) Caused by: java.lang.Exception: Native Assert. FILE=icsHE/GraphicsHorizon.cpp:161 MSG= at com.meta.spatial.core.SpatialInterface.nativeInit(Native Method) at com.meta.spatial.core.SpatialInterface.init(SpatialInterface.kt:134) at com.meta.spatial.runtime.VrActivity.onCreate(VrActivity.kt:223) at com.meta.spatial.toolkit.AppSystemActivity.onCreate(AppSystemActivity.kt:56) at com.mixed.reality.factory.LoaderQuestActivity.onCreate(LoaderQuestActivity.kt:59) at android.app.Activity.performCreate(Activity.java:8636) at android.app.Activity.performCreate(Activity.java:8614) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1456) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3789) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3947) at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103) at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:139) at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:96) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2468) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loopOnce(Looper.java:218) at android.os.Looper.loop(Looper.java:310) at android.app.ActivityThread.main(ActivityThread.java:8250) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:552) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:978) Any help would be highly appreciated.egrabhishek4 months agoHonored Guest42Views0likes0CommentsWhere anatomically is the HEAD joint
Not much detail here: https://developers.meta.com/horizon/reference/spatial-sdk/v0.7.0/root/com.meta.spatial.toolkit/body-joint/h-e-a-d Is it directly above where the spine meets the skull and behind the eyes? i.e. the "head atlas"? Is this a good pivot point for billboarding view screens?waynecochran5 months agoProtege86Views0likes3CommentsInterface of getting Controller joystick travel range
Hello, I’m fairly new to the Meta Spatial SDK, and while reviewing the Controller Input documentation, I couldn’t find any interface that allows retrieving the joystick’s travel range. What I came across were examples treating joystick directions as “Buttons” (like ButtonThumbRL). However, what I’m trying to do is map the joystick’s travel to an attribute like “velocity.” Is there any way to access this information? If I’ve missed something, my apologies, thank you!xiayip5 months agoExplorer208Views0likes5CommentsIs there a way to place a object in the hand instead of the contorllers
Hey, I am trying to make a shooting range application, and I wish for the weapon in the game to be in the place of the controller. I don't have a beefy computer and meet the bare minimum, and this was the only way I code for Quest 3 at the moment, which is through the Meta Spatial SDK. I see in the spatial Editor there is an AvatarBody Component that allows you to attach things to it, but I am reading that it allows you to use it in the sense of making your own Playable Avatar and using that to attach things to your avatar. there are no samples out there yet anyone figured out how to replace the controller model with another object yetsimplecast6 months agoMember105Views0likes0CommentsCustom Item Tracking using Spatial SDK
We are trying to implement a custom tracking system along with Quest's tracking. We want the headset to be able to detect custom gloves that we put in our hands, is it possible to train the current ml models or the Spatial sdk currently only uses the pretrained model?manrock77886 months agoHonored Guest90Views0likes0CommentsBinding objects in reality using spatial anchors
Hi, I'm new to development, so maybe my problem is too simple. But still, thanks in advance for any recommendations! I'm trying to create a very simple AR app for Meta Quest 3, following the official instructions on Meta's website. However, the result so far leaves much to be desired. My goal is to fix an object from a prefab onto a table in the real room. Later, I also plan to add UI buttons to the object to enable interactions — but that comes later. I'm using Unity version 6000.1.6f1. I’ve installed the Meta All-in-One SDK (v77) and decided to start by using the provided Building Blocks. I also installed the OpenXR plugin, as recommended. In Player Settings, under Active Input Handling, I selected Input System Package. In XR Plug-in Management, I selected OpenXR > Meta XR Feature Group. Under OpenXR settings, in Enable Interaction Profiles, I selected: Oculus Touch Controller, Meta Quest Touch Pro Controller and Plus Controller Profile. In OpenXR Feature Groups, I enabled: - Meta XR Feature, - Meta XR Foveation, - Meta Subsampled Layout, - Meta Quest Anchors, - Boundary Visibility, - Bounding Boxes, - Camera (Passthrough), - Display Utilities, - Meshing, - Occlusion, - Planes, - Raycast, - Session. In the scene, I added the following Building Blocks: Camera Rig, Passthrough, MR Utility Kit, Find Spawn Positions, Controller Tracking Left, and Controller Buttons Mapper. I added my prefab object (currently without UI buttons) and connected it to Find Spawn Positions. I also configured labels like “table” and other placement surface definitions. When I run the app, the room scan loads and the object appears as if it’s placed on a table — but the position is different every time, and sometimes the object ends up on the floor instead of the table. I also tried writing a simple script: when pressing the B button on the controller, a beam should be fired and an anchor placed where the beam intersects with a surface (using my prefab object as the anchor). But nothing happened when I tried this, so I abandoned the idea and looked for something ready-made in the Building Blocks. Eventually, I found the Instant Content Placement Tool. I added all three recommended objects to the scene: Environment Raycast Manager, Cube, Raycast Visualizer. However, when I launched the scene, the controller-based placement didn’t work. The cube simply appeared at the player’s origin point and stayed on the floor, without any movement or interactivity. Of course, I was also hoping to make the placed object stick to real-world surfaces and persist across sessions by saving its anchored position in the room scan — but I understand that this might still be far off. Could you please suggest a clear algorithm or sequence of steps for achieving this? It seemed like placing and saving an object in a room should be a simple task. But after spending a whole week trying to understand the Building Blocks and how everything connects, all I could manage was to place the object — and even that is inconsistent, with its position shifting slightly every time.KovalevBoris7 months agoExplorer437Views0likes4CommentsBatting cage tutorial issues with spawning ball above player location
I am trying to add to the batting tutorial and I am having issues spawning the ball above the players head. I have implemented a couple different ways but they dont work. They will compile but the collision detection doesnt work. I have recieved errors such as failed to call method 'start' as well as having the code work with error detection but break once the player moves. This is my current code: import * as hz from 'horizon/core'; type State = { originalPosition: hz.Vec3 } class BallScript extends hz.Component<typeof BallScript> { static propsDefinition = {}; originalPosition!: hz.Vec3; start() { // Listen for ball collisions with the ground. this.connectCodeBlockEvent(this.entity, hz.CodeBlockEvents.OnEntityCollision, (collidedWith: hz.Entity, collisionAt: hz.Vec3, normal: hz.Vec3, relativeVelocity: hz.Vec3, localColliderName: string, otherColliderName: string) => { // Move the ball back to its starting position above the local player's head. const localPlayer = this.world.getLocalPlayer(); if (localPlayer) { const playerPosition = localPlayer.position.get(); this.entity.position.set(playerPosition.add(new hz.Vec3(0, 2, 0))); // adjust the height as needed } // Reset the ball's velocity. this.entity.as(hz.PhysicalEntity).zeroVelocity(); } ); // Update the original position if the local player is already in the world. const localPlayer = this.world.getLocalPlayer(); if (localPlayer) { this.updateOriginalPosition(localPlayer); } // Listen for the player entering the world and update the original position. this.connectCodeBlockEvent(this.entity, hz.CodeBlockEvents.OnPlayerEnterWorld, (player: hz.Player) => { if (player === this.world.getLocalPlayer()) { this.updateOriginalPosition(player); } }); } // Update the original position of the ball to be above the player's head. private updateOriginalPosition(player: hz.Player) { const playerPosition = player.position.get(); this.originalPosition = playerPosition.add(new hz.Vec3(0, 2, 0)); // adjust the height as needed } // Get the original position of the ball so that it respawns in the same place. override receiveOwnership(state: State, fromPlayer: hz.Player, toPlayer: hz.Player): void { this.originalPosition = state.originalPosition.clone(); // clone the Vec3 to avoid modifying the original state if (toPlayer === this.world.getLocalPlayer()) { this.updateOriginalPosition(toPlayer); } } // Pass the ball's original position to the new owner. override transferOwnership(fromPlayer: hz.Player, toPlayer: hz.Player): State { return { originalPosition: this.originalPosition.clone() }; // clone the Vec3 to avoid modifying the original state } } hz.Component.register(BallScript);TerianDiLun7 months agoMember214Views0likes0CommentsPossible bug in Entity trySetMapvalue generic type argument
The trySetMapValue is using the generic key type for the value: public final inline fun <reified T, reified V> tryGetMapValue(attribute: kotlin.Int, key: T): V? { /* compiled code */ } public final inline fun <reified T, reified V> trySetMapValue(attribute: kotlin.Int, key: T, value: T): kotlin.Boolean { /* compiled code */ } Is this the intended behavior? Also, what's the purpose of the Entity map? I'm trying to use it to save the internal state of the entity, but I don't know if this is ideal.hsartori7 months agoHonored Guest176Views0likes0Comments
Quick Links
- Horizon Developer Support
- Quest User Forums
- Troubleshooting Forum for problems with a game or app
- Quest Support for problems with your device