breakpoint in a player

Is it possible to set breakpoint while the player in debug+script debugging is playing?
I attach to it and any breakpoint I’m setting in obsious places like update and ongui, same as in the player don’t stop the player
6182336--677216--upload_2020-8-8_1-31-44.png
is it how it’s done? Unity - Manual: Debugging C# code in Unity

Depending on target and operating system, the debugger may not correctly attach. The symptom of this is that a breakpoint hits but the executing target is not paused.

One solution is to close your debugger, close Unity, reopen Unity and reimport one of the scripts. It doesn’t always work but often it does. Other things that can help is to reboot your system. This is particularly true with Windows.

Another solution is to sprinkle lots of Debug.Log() statements through your code to figure out what it is doing. This is ALWAYS the fallback when the debugger refuses to attach.

1 Like

You could also try inserting a call to Debugger.Break.