Multiplayer problem

I am trying to create a mutliplayer system but facing some glitches mainly in camera . Can anyone please suggest me how to solve this problem . here is the code below

In heirarcy root tab, i have used the network script . Thats where the main problem arises … . Cannot find the solution

Hi @anya! It’s not clear to me which glitches you mean exactly, but to fix an error in your project I had to place your Other entity lower in the hierarchy than your Player entity.


i want to make it mutliplayer

I looked at the setup of other multiplayer projects and it appears that only the Player entity need the scripts and the camera. So you have to disable all scripts (playerMovement, playerAnimationHandler and cameraMovement) and the camera of the Other entity.

thank you so much @Albertos for the solution it woks fantastic .

One question,

the marked area in both the photos are same but characters are not loading for the other person . Please let me know if its a bug or something . Anyway thankyou for your help. You are a live saver .

1 Like

Did you change the character of the Other entity in your scene too?

yes, But nothing seem to work

The link of your project doesn’t work anymore, so if you share a new link someone can take a look.

and it starting showing some more bugs

I see you create your new character at runtime. That means you need to send the new character over the network to the other user and update the character there too.

If you see a new bug that wasn’t there before, check what changes you’ve made. This makes it easier to find out what is causing the new bug.

Okay do i need to make changes in network.js or another place ? because i have tried and how can i send the new character in real time .

I don’t know how you apply the new character, but I guess you change the materials? Then you have to send these materials in your network script (just like you send the position) and apply these materials on the other side too.