Possible to remove NPC detection of player? And can I access the code to send audio?

Original Discord Post by tyke_18 | 2024-08-30 07:03:18

Hi, in my MR app I’m having issues with the Convai NPC not detecting the player in order for a conversation to happen (I’m getting the Not Close Enough message or NPC Not Active message), it’s probably something I’m doing wrong but I don’t want this feature in my app if possible, the user should be able to speak to the NPC wherever they are etc, can I remove this? I’ve tried increasing the collider size so it’s really big and setting the ray size to very large and view angle to 360 but no luck.

I don’t want a Ground gameobject in my app so I’ve removed it but then the player kept falling through the floor, so I edited ConvaiPlayerMovement line 27 to this private float gravity = 0f;

Also, I don’t want to use the VR upgrade package if possible, my app is an MR app on a Meta Quest 3 which uses dynamic occlusion, I need to use Unity Standard Shader shaders and I think the VR upgrader requires URP to be installed? Another reason is because I don’t want to have to install the XR Interaction Toolkit so I can use the VR controller as an input.

My app already has code to detect the right trigger being pressed for Talk, I appreciate I could remap this in the Input Manager but there’s nothing I can see that lets me use the Menu button (I use this button)? I would prefer it if I could just have access to the code that sends the audio to the Convai servers, with Inworld I called an Inworld method called SendAudio() when the right trigger was pressed for push to talk, is there a similar method or bit of code in Convai?

Sorry for the wall of text, I’m really liking what I’m seeing so far, it’s a bit difficult learning a new SDK and API again but your docs are very good, loving the new Long Term Memory and how easy it is to implement!

Reply by k3kalinix | 2024-08-30 07:06:17

Hello <@708608540763357234> :wave:t2:,

Reply by k3kalinix | 2024-08-30 07:08:52

Actually you can use manual installation for VR.

Reply by k3kalinix | 2024-08-30 07:09:55

And this notification occurs when there is no active NPC.

Reply by k3kalinix | 2024-08-30 07:10:08

I’ll help you in 3-4 hours, okay?

Replying to k3kalinix’s Message

Reply by k3kalinix | 2024-08-30 07:08:52
Actually you can use manual installation for VR.

Reply by tyke_18 | 2024-08-30 07:35:18

Hi K3, 3-4 hours absolutely no problem, thank you :slightly_smiling_face:

Reply by k3kalinix | 2024-08-30 10:44:15

Hello <@708608540763357234>

Replying to k3kalinix’s Message

Reply by k3kalinix | 2024-08-30 10:44:15
Hello <@708608540763357234>

Reply by tyke_18 | 2024-08-30 10:46:08

Hi K3, can you give me 10-15 mins please? I am just preparing 2 videos to demo my issues, no problem if you can’t wait.

Reply by k3kalinix | 2024-08-30 10:46:19

it is okay.

Reply by tyke_18 | 2024-08-30 11:03:14

Hmm my project when run in the Unity editor runs ok but when I build for Quest 3 it crashes on startup, so I can’t show you the NPC NotActive messages I get in the Quest 3 debugger window at the moment, sorry. Here is some info and a video I prepared but I need to get the Quest 3 build version working to show you what’s happening in the Quest 3, do you think the Quest 3 build is failing because of these URP warnings after I build and deploy to the headset?

Images:


Reply by tyke_18 | 2024-08-30 11:03:33

Embedded Content:
Convai VR build running ok in the Unity editor
Convai VR build running ok in the Unity editor
Link: https://www.youtube.com/watch?v=MDbtvoiSt0w

Reply by tyke_18 | 2024-08-30 11:03:50

-I did the manual method of setting up VR, the only package I did not install was URP (Universal Render Pipeline) as I don’t want to use these shaders.

-I chose all of the options during the import process after the ConvaiVRUpgrader package was double clicked.

-I then did Add the Convai Essentials VR prefab to your scene.
Add NPCManager and GRPCApi components to your Meta Quest Player.
Add the ConvaiHandPanelHolder object to your left hand (you can find it by searching Hiearchy).
Remove Convai VR Player.

-I have the Unity active input system set to ‘new’

-How do I install the Convai VR package without having to make my project URP? I think the package changes some settings to do with URP shaders because my avatar when applying dynamic occlusion using BiRP / Standard shader has errors and crashes the app when run in the Quest 3.

Reply by k3kalinix | 2024-08-30 11:07:26

Could you please delete the Convai VR Player gameobject?

Reply by tyke_18 | 2024-08-30 11:09:03

Done, I’m building for the Quest 3 again right now. Just to note this an MR app not a VR app, not sure if that makes a difference.

Reply by k3kalinix | 2024-08-30 11:09:19

No not important

Reply by k3kalinix | 2024-08-30 11:10:00

okay

Reply by k3kalinix | 2024-08-30 11:10:18

How do you install this apk on your device?

Reply by tyke_18 | 2024-08-30 11:11:36

With Meta Quest Developer Hub, just tried again with VR Player deleted, crashes at start up. Yesterday it was just crashing sometimes. What do you think about the Input Manager script not listing keys/buttons etc?

Reply by k3kalinix | 2024-08-30 11:11:57

Can i see quest 3 logs?

Reply by tyke_18 | 2024-08-30 11:12:31

Hang on I’ll run it again and get the error logs from MQDH.