This document is about: FUSION 2
SWITCH TO

Breakpoint Support

Overview

Starting from version 2.0.5, the Fusion SDK introduces enhanced support for breakpoints, specifically designed to improve the debugging experience. This feature allows developers to set and manage breakpoints more efficiently in both Multi-Peer and Unity MPPM environments. Developers can easily pause execution, inspect variables, and step through code, making it easier to identify and resolve issues within their applications. This enhancement is part of our ongoing commitment to provide robust and developer-friendly tools within the Fusion SDK.

Limitations

  • Only Client-Server Modes are supported (Host, Server, Client).
  • Peers must be running on the same machine, either via Fusion Multi-Peer Mode or using Unity Multiplayer Play Mode (MPPM).
  • Support is limited to Debug Builds and will be disabled when using Fusion in Release Mode.

How to use

This is an extension of the "Photon Cloud Connection Lost" feature, that allows Client-Server peers to stay connected even if the connection with the Photon Cloud ceases.
Read more about this feature at Photon Cloud Connection Lost.

  1. Increase the Network / Connection Timeout to the max time for debugging purposes on the NetworkProjectConfig.
  2. Set up the project accordingly, depending on whether you are using:
    1. Fusion Multi-Peer Mode: check the instructions here
    2. Unity Multiplayer Play Mode: check more details here
    3. Neither : no specific setup required
  3. Set up the breakpoint via IDE and attach it to the Unity process.
  4. Run the game and wait for the breakpoint to be hit.
  5. You should be able to see the peers still connected and the game freezing while the breakpoint is active. The game should continue after the breakpoint is released up to the timeout limit.
Back to top