Search Unity

How do i get the NetworkConnection conn parameter of a specific Client

Discussion in 'Multiplayer' started by Jackdahack, Jan 17, 2019.

  1. Jackdahack

    Jackdahack

    Joined:
    Sep 11, 2018
    Posts:
    9
    I want to use the methode NetworkServer.SetClientReady(). For this i need the parameter NetworkConnection conn of the Client. So far i only used the ConnectionId to send and recieve datas between server and the client.

    My code should work like this: I've send a data package from the client when the game scene is loaded, to let the server know that the client is ready to recieve datas like other logged in clients and positions of the other players. The server should then constantly send position datas and other stuff to all clients that are set to ready.
     
  2. mischa2k

    mischa2k

    Joined:
    Sep 4, 2015
    Posts:
    4,347
    Every NetworkBehaviour has '.connectionToServer' on the client.