Search Unity

Third Party UNET/Mirror: NetworkServer.SendToAll received on client but not on host

Discussion in 'Multiplayer' started by shahzaib, Aug 30, 2021.

  1. shahzaib

    shahzaib

    Joined:
    Dec 14, 2013
    Posts:
    32
    hi

    I have a bit of a situation here, so this is more or less what my code looks like, if I have more than one player (1 host and 1 client) and SendSnatchMessage is called, it is received on clients and OnVehicleSnatched triggers every time, but the host doesn't receive anything as if nothing triggers on the host but if there are no clients and host is alone in the game, it receives SnatchMessage every time.

    I'm trying to sort this out for the last 3-4 hours, it's very frustrating that I am not getting any warnings or errors and yet, my code doesn't work or work in ways I expect not to.

    upload_2021-8-31_0-49-32.png