Set up Visual Studio Code for Unity [MAC/PC 2023]

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
Microsoft and TNT had recently released a new package that makes Visual Studio code integration much better and faster to set up if you don't have Visual Studio code installed the one with a blue icon simply download it from the official website openmt and make sure that your project is on UT 2019 or newer older versions might not work in your project go to window package manager select into registry and search for visual studio you will probably get those two results the first one Visual Studio code editor is a legacy package and we should remove it click on it and select remove the second one Visual Studio editor is the one that is interesting to us click on it and make sure that the latest version is installed there is a chance that your project already has it but you need to update it once it is done close this window and steal annuity go to Unity settings or on Windows edit preferences and on the left select external tools tab here we can select what is our default script editor in this drop down you should already see Visual Studio code option if not click browse and find it in one of the paths displayed below once selected you'll probably see these gray texts saying Visual Studio editor 2. something enabled that is a good sign at the end click regenerate project files now close this window and go to assets open c-sharp project that should open a new Visual Studio code window with your project files but we are not done just yet because the suggestions are still not working go to the extensions Tab and search for Unity this is an official package that will handle all the setup for us just click install the install itself may be very quick but it will probably take a second to download all required.net dependencies in the background wait till here in the bottom left you will see projects and a number now restart the visual studio code just close it and open it once again through the unity opencsharp project option this time after the second of loading you should see a new window with intellisense suggestions fully working Try It Out by typing for example transform that position equals Vector 2.1 if it works leave a like under the video thanks here are a few quick tips and extensions to install first install Unity toolbox extension it will enable some code Snippets like awake on enable it will also show you info about UNT built-in methods and some descriptions if you forget what each one does don't like those small gray texts above each method go to visual studio code settings and search for code lens you can disable them just like that if you'd like to debug your code place a breakpoint next to the code line go to the run and debug Tab and click Start debugging if you see this pop-up click enable debugging for all projects now when your code will reach this breakpoint a visual studio code will show up and the last one remember that Visual Studio code has amazing theming capabilities just go to code settings theme color theme and check out the different options my favorite one is monokai or even monokai plus plus from the extensions page as always thanks a lot to my awesome patrons that support this channel see you soon
Info
Channel: Coco Code
Views: 23,538
Rating: undefined out of 5
Keywords: unity visual studio code, visual studio code, unity vsc, vsc, microsoft code, unity IDE, VSC IDE, Unity IDE, Install visual studio code, intellisense working, visual studio code intellisense
Id: X8Qr78Vs0Ss
Channel Id: undefined
Length: 3min 48sec (228 seconds)
Published: Thu Sep 28 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.