NWH Vehicle Physics 2
Search Results for

    Show / Hide Table of Contents

    Mirror

    Setup guide for NWH Vehicle Physics 2 multiplayer using Mirror framework.

    Warning: Before starting make sure that your vehicle and scene are already set up for single-player. If not, check the Quick Start guide.

    Setting up the scene

    • Create a new GameObject called 'NetworkManager'.
    • Add the following components to the created object:
      • NetworkManager
      • NetworkManagerHUD
      • TelepathyTransport (or other transport if you are not using Telepathy). In newer versions of Mirror KcpTransport is the default.
    • Your object should look like this:

    20200313-152404.png

    Setting up the vehicle

    • Double click on Mirror.unitypackage (NWH\Vehicle Physics 2\OptionalPackages\Multiplayer) to import the required assets.
    • Add MirrorMultiplayerVehicle component to the vehicle. This will also add necessary Mirror components automatically.
    • Make sure that NetworkTransform's Client Authority field is ticked.
    • Set Network Sync Interval to 0.05 (20Hz). Default value is 0.1 (10Hz) and is too low for physics objects and will result in stuttering.
    • Set Compress Rotation to None.
    • If you want to further reduce stutter reduce all three Sensitivity field values.
    • Save the vehicle as a prefab and assign it to NetworkManager's Player Prefab field.
    • Your vehicle configuration should now look like this:

    20200313-153813.png

    In this article
    Back to top Copyright © NWH - Vehicle Physics, Aerodynamics, Dynamic Water Physics