Debugging in Unity (C#) + Visual Studio Code Work

2020-06-08 05:09发布

I really like the idea of working with Visual Studio, C# and Unity on OS X.

Has anyone made debugging with C# in Unity work with Visual Studio Code on OS X?

8条回答
你好瞎i
2楼-- · 2020-06-08 05:49

The Unity Debugger for Visual Studio Code is working, but doesn't work well enough when doing any kind of serious work for now. I really hope they will improve it in the future as I prefer VS Code over VS.

Current problems I encountered -Sometimes I cannot step in a function, the debugger will hang until you detach -no local variable, you have to watch everything -some more complex variable have no support, so you can't see what is inside -A bit overall unstable with unexpected behaviours.

What I love about it, Attaching & Detaching is a breeze. Just press a button, allowing to attach and detach quickly as needed. e.g. At the beginning of the program I work on, there will be an bunch of exception. I can detach and attach quickly to skip the exceptions.

The problems with it are too constraining as it currently stands, I had to go back to the classic Visual Studio.

查看更多
Explosion°爆炸
3楼-- · 2020-06-08 05:57

An existing Visual Studio solution can be build and debugged with Visual Studio Code on the Mac with Mono. You have to use the launch.json and tasks.json files. I described it on my blog: Compile and Debug

enter image description here

查看更多
登录 后发表回答