Search Unity

Question NetworkObject disable trigger events

Discussion in 'Netcode for GameObjects' started by CodeExc, Dec 12, 2021.

  1. CodeExc

    CodeExc

    Joined:
    Oct 31, 2016
    Posts:
    8
    Hi,

    I have a NetworkObject with a BoxCollider as trigger.
    When the host call the OnTriggerEnter() event, the event is also triggered on the clients.
    It does not work from the clients to the host-side.

    Can I disable these network events and only call them on the respective client?
    Otherwise I get problems in the ServerRpc() methods, because they are always called multiple times on the client.