In the Unreal Engine 4.18 release notes there is a note saying VS Code is now supported on Mac, Windows and Linux. Awesome! I would like to use VS Code on my macintosh.
When I selected VS Code as my editor, however, I ran into multiple problems with unclear interface or documentation. For the following, I am running Unreal Editor 4.18.0-3709383+++UE4+Release-4.18 on Mac OS X 10.12.6 (16G29) with XCode 9.1 (9B55) and VS Code 1.18.0 installed. I added VS Code to a project by selecting VS Code as my “source code editor”, adding a C++ file, and selecting “Open VS Code” from the File menu.
-
Your public messaging does not correctly indicate how to enable VS Code. The only note I find about VS Code on mac is the 4.18 release note. The release note says “To use it, select ‘Visual Studio Code’ as your preferred IDE from the editor preferences dialog”. This is actually not accurate, the preference in the preferences dialog is titled “source code editor”. The wording matters because the preferences dialog is very long and it has a search box that takes a string. It took me some time to figure out how to enable VS Code because I was searching the preferences dialog for “IDE” when I should have been searching for “Source code editor”. My expected behavior is that the release note should say “source code editor” instead of “IDE”. An even better expected behavior would be that there should be an actual page in the documentation explaining the source code editor preference and what the supported options are on each platform.
-
You have not set a “default” build task, which makes it very confusing as a new user how to build or clean. When I execute “run build task”, I see this:
"UnrealTSTemplate" is the name of my project. However this is disorienting: As a new user I do not understand the difference between "Debug", "DebugGame", "Development", and "Test". I also do not understand the difference between "UnrealTSTemplate" and "UnrealTSTemplateEditor". I **do** find, in the Unreal documentation, [this page](https://docs.unrealengine.com/latest/INT/Programming/Development/BuildConfigurations/index.html) which explains the difference between all of these different options. However it took me a while to find this page and understand what it is saying (I'm honestly still a little confused— I think I want "Editor" "Development"?)
By comparison, this is what XCode looks like:
In XCode, there is no ambiguity. XCode is preconfigured to build in some appropriate mode (I assume "Editor" "Development"). VS Code **could** also be preconfigured to build in the appropriate default mode. The proper way to do this in VS Code is with the "isDefault" key in `tasks.json`, [as documented here](https://code.visualstudio.com/docs/editor/tasks). If I edit my `tasks.json` so that the development build stanza says:
`"taskName": "UnrealTSTemplateEditor Mac Development Build", "group": { "kind": "build", "isDefault": true },`
...instead of just `"group": "build"`, then "Run Build Task" will build that instead of bringing up the new-user-unfriendly menu.
My **expected behavior** is that when you generate a `.vscode`/`tasks.json`, you should write the `isDefault` flag for the appropriate default (ie: whatever the default is on XCode). An **even better expected behavior** is that in addition to setting the `isDefault` flag, you could make the Build Configurations Reference page more new-user friendly by putting a sentence in the introduction explicitly saying "The recommended configuration when developing with Unreal Editor is Development/Editor" (or whatever). This would have helped me figure it out quicker. (You do say midway down the page that Development is the default in that category, but one has to read the entire page to realize this.)
- There is no “clean all” option. As shown above there are many configurations, VS Code’s interface for presenting configurations is less helpful than that of other IDEs and unfortunately VS code does not seem to(?) have a “default clean” option the way it does a “default build” option(?). VS Code also unfortunately does not have a “clean all” option like normal Visual Studio does. It is not obvious to me from either the configurations reference page or the interface whether cleaning (for example) the Mac DebugGame configuration will also clean the Mac Development configuration. Because of this it would be very helpful, especially to new users, if there were by default a “Clean All” task in VS Code which cleans all installed configurations and platforms.