Can't see other player

Both players enter the same room but we can't see each others avatar. What could be the problem? I followed the basic Player Controller tutorial. It's on WebGL. Our API key is upgraded to WebGL.
Solution:
I think it was because I had multiple avatar child prefabs (deactivated) in one player prefab. I just activated the one the player chose in character selection and figured it would work. But it didn't so I have made multiple Player prefabs with each there own avatar prefab and that seems to work.
Jump to solution
9 Replies
kapa.ai
kapa.ai7mo ago
Hi @Hippolicious || CardaStacks. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- There could be a few reasons why you're not seeing each other's avatars in the room. Here are some things you can check: 1. Avatar Prefab: Ensure that you have correctly set up your avatar prefab and it is correctly linked in the RealtimeAvatarManager component under “Local Avatar Prefab”. The avatar prefab should be in a Resources folder so it can be instantiated at runtime. You can refer to the XR Avatars and Voice Chat guide (https://normcore.io/documentation/guides/xr-avatars-and-voice-chat) for more details. 2. RealtimeTransform Component: Make sure you have added a RealtimeTransform component to the Player to synchronize movement and a RealtimeTransform on the character game object so you can synchronize the character look direction and lean. You also need to call RequestOwnership() on each RealtimeTransform when the prefab is instantiated to signal that all other clients should use this client's transform as the source of truth. You can refer to the Creating a Player Controller guide (https://normcore.io/documentation/guides/creating-a-player-controller#making-it-multiplayer) for more details. 3. Script Execution: If you have a script on your player, it should be updating only the local player and not all players in the room. You can use RealtimeView’s isOwnedLocallyInHierarchy property to ensure that your code only executes on local and not remote avatars. You can refer to the Common Questions section (https://normcore.io/documentation/realtime/common-questions#i-have-a-script-on-my-player-why-is-it-updating-all-players-in-the-room) for more details. 4. WebGL Support: Normcore's WebGL support is designed to allow any Normcore project to be compiled for WebGL with no modifications to the source project. Make sure you have followed the steps to create a build of the Player Controller sample for the web along with voice chat as described in the WebGL guide (https://normcore.io/documentation/platforms/webgl). If you've checked all of these and you're still having issues, it might be a good idea to reach out to Normcore's support for further assistance. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai7mo ago
<@366873530199179264> kapa.ai is still learning and improving, please let us know how it did by reacting below
Hippolicious || CardaStacks
1. We are not making an XR game and the Hoverbird example does not have that component so I am disregarding this one. 2. Have done this and followed the Player Controller Guide 3. Also done this. 4. Done everything except the voice chat yet. But that is not the issue here. Some additional information: According to the console we are indeed connected to the same room. We just don't see each other. I will keep searching and keep you updated. Got it working but not sure what the actual problem was. I will keep you posted 😅
Towellie
Towellie7mo ago
Congrats on finding a fix! Please let me know what the solution was so we can improve Normcore Assistants responses!
Solution
Hippolicious || CardaStacks
I think it was because I had multiple avatar child prefabs (deactivated) in one player prefab. I just activated the one the player chose in character selection and figured it would work. But it didn't so I have made multiple Player prefabs with each there own avatar prefab and that seems to work.
Mechabit
Mechabit7mo ago
you've probably figured out that active state isn't synced out of the box, for that you need to use a custom model and sync an int for chosen character
Mechabit
Mechabit7mo ago
Synchronizing Custom Data | Normcore Documenation
In this guide, I’m going to walk you through how to synchronize custom data in your Unity application using custom realtime components.
Mechabit
Mechabit7mo ago
is that comment for another thread?
xulipa
xulipa7mo ago
Ohh sorry you are right I was in a wrong thread.