Search Unity

Get ping in new transport layer?

Discussion in 'Entity Component System' started by major-quin_n, Jan 1, 2020.

  1. major-quin_n

    major-quin_n

    Joined:
    Mar 11, 2016
    Posts:
    1
    Hello,

    Is there an easy way that I can get the ping to a client on my server?

    Love the work so far, didn't have much issue converting my code from Lidgren. Just noticed this was not present.

    Working on a FPS game and need server-side rollback for raycasting ;)
     
    Opeth001 likes this.
  2. timjohansson

    timjohansson

    Unity Technologies

    Joined:
    Jul 13, 2016
    Posts:
    473
    Ping is not something you get out of the box right now, the transport is not sending any periodic packages and does not know which packages are responses to what so it is something you have to do on top of the transport for now. The ping samples from https://github.com/Unity-Technologies/multiplayer/ calculates RTT.