PUN Classic (v1), PUN 2 and Bolt are in maintenance mode. PUN 2 will support Unity 2019 to 2022, but no new features will be added. Of course all your PUN & Bolt projects will continue to work and run with the known performance in the future. For any upcoming or new projects: please switch to Photon Fusion or Quantum.

Custom Configuration

If you want to customize the bolt configuration through code before starting your server or client, you can do so by calling BoltRuntimeSettings.GetConfigCopy, modifying the returned object and then passing it as the last argument to StartClient or StartServer.

You have access to more settings that are not exposed in the Bolt Settings window through code.

C#

    BoltConfig config = BoltRuntimeSettings.instance.GetConfigCopy();

    // change any settings you want on the config object here,
    // be aware that bolt will not verify/limit any settings when you do
    // it directly in code, so you can break things completely by supplying
    // incorrect/invalid config values.

    BoltLauncher.StartServer(new UdpEndPoint(UdpIPv4Address.Any, 27000), config);
Back to top