Search Unity

Please help!!!

Discussion in 'Multiplayer' started by Et3rnos, May 17, 2018.

  1. Et3rnos

    Et3rnos

    Joined:
    May 9, 2018
    Posts:
    14
    I have a problem: When I start my game (with host and client), I can see host player moving in client game but I can't see client player moving in the host game. Does anybody know the solution?
     
  2. ThermodynamicsMakesMeHot

    ThermodynamicsMakesMeHot

    Joined:
    Feb 14, 2015
    Posts:
    224
    All depends on what your using. You likely have not told the API to view the network objects.

    For instance: Photon requires a network view to be attached. // Unet requires the same or if your using newer version: NetworkIdentity.

    Basically if you do not sync the objects/scripts/animations over the network and tell the network that these are network objects and to "watch them - View", you will only see it on the host client, not across the server.
     
    Et3rnos likes this.
  3. Joe-Censored

    Joe-Censored

    Joined:
    Mar 26, 2013
    Posts:
    11,847
    You're not saying anything useful to help you get an answer.

    What networking API are you using?
    Where is your code? Post it using Code tags.
    What have you tried already?
    How are you handling movement of client players?
    Are you moving them locally and syncing to the server?
    Are you sending movement commands to the server and then syncing the moved player back to the client?
     
    Last edited: May 17, 2018
    Et3rnos likes this.
  4. thesupersoup

    thesupersoup

    Joined:
    Nov 27, 2017
    Posts:
    70
    I highly recommend viewing the following YouTube tutorial on synchronizing players over the network:


    And the follow up:


    That should get multiple players synchronized between host and client.
     
    Et3rnos likes this.
  5. Et3rnos

    Et3rnos

    Joined:
    May 9, 2018
    Posts:
    14
    Thanks but I have already found the solution: Check the LOCAL PLAYER AUTORITY box in network identity script.
    Thanks for the help!