Search Unity

Official Update on the Visual Studio Code package

Discussion in 'Code Editors & IDEs' started by Frederic_Peltier, Jun 30, 2022.

Thread Status:
Not open for further replies.
  1. luistapia2998

    luistapia2998

    Joined:
    May 20, 2021
    Posts:
    3
    Just like in the old days, with a text editor in one hand and documentation on the other.
     
  2. Unib0t

    Unib0t

    Joined:
    Jan 4, 2013
    Posts:
    15
    Script Inspector 3 doesn't support debugging, unfortunately.
     
  3. GrassWhooper

    GrassWhooper

    Joined:
    Mar 25, 2016
    Posts:
    109
    i really miss mono develop on windows now eh
     
  4. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    On the flip side it's nearly free which is the requirement of the person that I quoted. If debugging through the use of breakpoints and not just relying on testing and logging frameworks is what you're after the only choice for Linux is going to be Rider which is $14.90 per month or $149 per year. That's significantly more expensive than SI3.
     
    Spy-Master likes this.
  5. GrassWhooper

    GrassWhooper

    Joined:
    Mar 25, 2016
    Posts:
    109
    there is this editor in case anyone is interested
    seems like the next best choice, definitely not using rider, or i'll just go back to monodevelop (which sadly, it appears that, there is no binary and we have to build it from source eh)

    consulo.io
     
  6. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Only if by next best choice you mean the only remaining free one. My searches suggest that it's not a very good editor, that it's sluggish (which was one of the main motivating factors for people to switch to VS Code), etc. I'm getting the impression that it's basically Rider minus everything that makes Rider a solid IDE and worth using.
     
    Last edited: May 7, 2023
  7. AntKnight23

    AntKnight23

    Joined:
    Aug 28, 2022
    Posts:
    2
    What do you mean
    >> Microsoft doesn't even make the extensions we use to support C# development in Visual Studio Code.

    https://marketplace.visualstudio.com/items?itemName=ms-dotnettools.csharp

    Isn't this extension maintained by Microsoft?

    And don't you see the lines below:
    >> with extensions to support just about any programming language.
     
  8. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Yeah someone pointed that out to me the other day in another thread. I had searched up OmniSharp and just assumed that the group that made it had made that extension too.

    Yes, it can support any programming language, but it's primarily advertised for web development.
     
  9. thenetimp

    thenetimp

    Joined:
    Sep 11, 2021
    Posts:
    12
    I dropped them like a rock when they went the subscription model route.
     
  10. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Jetbrains calls it a subscription but it's much more akin to an auto-renewing perpetual license since you don't lose access to the releases that came out while your subscription was active. Just subscribe for a year to gain access, cancel it before it renews again, and then when you need an update resubscribe.
     
    Last edited: May 14, 2023
  11. thenetimp

    thenetimp

    Joined:
    Sep 11, 2021
    Posts:
    12
    i'm happy with VSC, One IDE for all the stuff I have to do in all the languages I have to do them in. I'll change if it stops working.
     
  12. borkom_unity

    borkom_unity

    Joined:
    Jul 22, 2021
    Posts:
    13
    pls fix debugger i hate using raider
     
    rod_lopez likes this.
  13. laurentlavigne

    laurentlavigne

    Joined:
    Aug 16, 2012
    Posts:
    6,362
    That's a free pass :D
     
  14. Well I would hate it too if I were using a raid tool for software development...
     
  15. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    That's great! I'm trying this out now.

    Since Unity dropped the VSCode support, I've been hanging to it, but it's decaying and become unwieldy at times. It has focus issues, then it suddenly just starts eating CPU and memory until they're all gone, needs to be killed manually. I've been just swiping the issue under the carpet but I swear this was the last time.
     
  16. TeaDrinkingProgrammer

    TeaDrinkingProgrammer

    Joined:
    Jun 1, 2023
    Posts:
    1
    This is a disgrace and the same S*** Microsoft have been pulling constantly. You go online, find that Unity has Linux support and you find an official guide for VScode, and it turns out that there is actually no support for it. This is the case for the whole C# ecosystem, where full cross-platform compatibility is a sham or is half-baked.
     
    Deleted User and borkom_unity like this.
  17. Spy-Master

    Spy-Master

    Joined:
    Aug 4, 2022
    Posts:
    618
    The model seems slightly wacky, you only access the versions that you had access to for a year (going by this document). But yeah, auto-renewing perpetual license. Perhaps it's alright if one specifically subscribes around late stability patch releases (edit: the document specifies patches are included, so timing doesn't seem to matter), though I can't picture so many people willing to pay for that duration who wouldn't just stay subscribed after that.
     
  18. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    Youre not insinuating that Microsoft would break standards in an effort to control the markets and to make financial profits at the expense of everybody else? I would say the monthly changing standards and APIs are just accident and bad luck......
     
  19. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    There is a community maintained fork of the package for VS Code. Latest releases require Unity 2021.3+.

    https://github.com/Chizaruu/com.tsk.ide.vscode
     
  20. itsjase

    itsjase

    Joined:
    Apr 18, 2017
    Posts:
    4
  21. Slashbot64

    Slashbot64

    Joined:
    Jun 15, 2020
    Posts:
    323
    Does anyone know if they finally got around to fixing this issue.... ie

    #if STUFF
    <this would be in color>
    #else
    <and this would also be in color>
    #endif

    the color highlighting for active symbol definitions never damn worked.. so made looking and working with large code blocks with lots of that stuff a nightmare.. thus vscode was good as garbage for most c# stuff, its debugger wasn't great with unity anyway.. shame really all the extensions and customization make it better than visual studio.. and I still use it for other languages... maybe they finally got around to improving it?
     
  22. TheSleepyKoala

    TheSleepyKoala

    Joined:
    Aug 24, 2018
    Posts:
    24
    Constant complaints won't lead to a satisfactory state for the debugger. Instead, we need to provide active support and show it some love. It would be great if someone with extensive Unity experience could step in and contribute.

    Colour highlighting shouldn't be considered a significant issue. With some effort, you can pioneer and create an extension to address it. There are numerous guides available on this topic. I made one for .jslib to test it out when I couldn't find an existing solution.

    Unfortunately, to my knowledge, your question's still an unresolved issue. However, I suggest submitting a feature or suggestion request since the maintainers have recently become more active and responsive.

    You can make your request here: https://github.com/dotnet/vscode-csharp/issues

    Many developers highly advocate open-source projects; fortunately, we can contribute to the vscode C# extension. So let's make the most of it.
     
    orionsyndrome and sqallpl like this.
  23. borkom_unity

    borkom_unity

    Joined:
    Jul 22, 2021
    Posts:
    13
    that dev kit sux too it comes with VS license from what i read
     
  24. Slashbot64

    Slashbot64

    Joined:
    Jun 15, 2020
    Posts:
    323
    You can make your request here: https://github.com/dotnet/vscode-csharp/issues
    ... they've been requested for years lol... here are a select few I've followed for ...years.

    Code wrapped in defines not highlighting correctly with Unity #2461 ..2018

    https://github.com/dotnet/vscode-csharp/issues/2461

    (related) Support syntax highlighting with tree-sitter
    https://github.com/microsoft/vscode/issues/50140 ..2018

    Allow customization of mouse shortcuts 2016 ...

    https://github.com/microsoft/vscode/issues/3130

    Add an optional configurable toolbar below the menu (with API for extension devs to use).. 2018

    https://github.com/microsoft/vscode/issues/41309

    "Good thing that the code editor from micrsoft when used by the language made by microsoft is unable to do simple syntax highlighting. What an age of technology we live in"
     
    TheSleepyKoala and Ryiah like this.
  25. borkom_unity

    borkom_unity

    Joined:
    Jul 22, 2021
    Posts:
    13
  26. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    It's a fork of the official package with community patches. If the original supported Linux I don't see any reason this shouldn't either. I haven't bothered to test it though as I have a subscription to Rider.
     
  27. TheSleepyKoala

    TheSleepyKoala

    Joined:
    Aug 24, 2018
    Posts:
    24
    I certainly hope so. I've invested considerable time and effort into further developing the package after all.

    As Ryiah mentioned, this is a fork of the official package, and there's no apparent reason why Linux support shouldn't be included.

    If you encounter any Linux-related problems, please don't hesitate to create an issue in the repository. I'm always happy to help! :)
     
    Grizmu, borkom_unity, Thaina and 2 others like this.
  28. borkom_unity

    borkom_unity

    Joined:
    Jul 22, 2021
    Posts:
    13
    @TheSleepyKoala ty dude you are god :), now i dont have to use rider anymore. Anyway one question i am using vscode extension "Debugger for Unity v3.0.11Preview by deitry" cuz i know it worked before with unity, should i use this or offical unity vscode extension ?
     
  29. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Official is dead.
     
    TheSleepyKoala likes this.
  30. TheSleepyKoala

    TheSleepyKoala

    Joined:
    Aug 24, 2018
    Posts:
    24
    Not god, I can't handle nor do I want that title I'm afraid. :eek:

    Just an upset Australian trying to make sure his dev space is secure. :)
     
    Thaina and borkom_unity like this.
  31. sasob8

    sasob8

    Joined:
    Jul 11, 2017
    Posts:
    25
    I don't understand why Unity isn't updating this package, but community is? Can someone explain for "simple people" like me? :)
     
  32. Adrian

    Adrian

    Joined:
    Apr 5, 2008
    Posts:
    1,066
    You could start by reading through this thread. The first post gives Unity's official explanation, I made some speculation later in the thread.

    Note that there are two extensions:
    • The VSCode extension for Unity, which is a Unity package and required for basic IDE-functionality in VSCode. @TheSleepyKoala is maintaining and further developing a fork.
    • The Unity debugger extension, which is a VSCode extension and is required for connecting the VSCode debugger to Unity. There have been a few forks, like the one from deitry, that popped up on VSCode marketplace but they're all pretty outdated and none of them have stayed active for very long. At least the basic functionality is still working, even with the deprecated original extension from Unity.
     
    TheSleepyKoala, Ryiah and Spy-Master like this.
  33. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Unity never provided support for this package and we were never told why. The community is picking it up for the simple reason that the community uses it.
     
    TheSleepyKoala likes this.
  34. Thaina

    Thaina

    Joined:
    Jul 13, 2012
    Posts:
    1,165
    To be fair, I think unity have said that both rider and vs package was provided from Rider team and Microsoft team. They just include it as official support. Only vscode package was made by unity and now they don't want to bear the burden of maintaining it anymore

    But it also disappointed that unity don't have a way to register custom package as default package. And also don't have a sensible way to do versioning with git package
     
    Ryiah and TheSleepyKoala like this.
  35. LoneGoat

    LoneGoat

    Joined:
    Dec 16, 2020
    Posts:
    21
    I recall some company talking about "democratizing game development", but just can't quite remember....

    Who care about antiquated ideals when there's money to be saved.

    Disapointing that there hasn't been a single response from a Unity representative on an issue that must effect a significant portion of their user base.
     
  36. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    @TheSleepyKoala s fork is working for me, thanks a lot for the work.

    I had to do these steps when switching, don't know if they're related to the switch or something else:
    1. Remove the Visual Studio Code Editor package
    2. Delete all your .csproj files
    3. Close VSCode
    4. Delete .vscode directory
    5. Install the TSK VSCode Editor package as instructed: https://github.com/Chizaruu/com.tsk.ide.vscode
    6. Unity Preferences->External Tools->Regenerate project files
    7. Unity Preferences->External Tools->Use Code-Workspace check + Reset to Workspace Default
    8. In VSCode Settings->"window.restoreWindows": "preserve"

    The highlighted step 4 was the only working fix to Omnisharp being completely stuck and throwing errors into Extension Host log. The final steps make it so that double-clicking things in Unity takes you to the correct file+line while keeping your workspace tabs intact.

    I think this community fork is the only thing that kept me from buying Rider. I'm a long-term IntelliJ user for Java (IDEA) but that one's free to use. I disagree that a developer needs to pay a hundred a year just to be Microsoft-compatible, just to support their language that's supposed to be free. Then again, many are happy to use VS, but I'm just not going there, it's a step too deep into a world of Microsoft bloat. An editor is supposed to be lightweight and to integrate with command-line use, instead of a monolith that mixes editing and runtime environments. For years (two decades) I have kept all Java projects editor- and platform independent by just keeping workspaces clean.

    All kudos to @TheSleepyKoala for his great work and I hope this fork will thrive and stay alive for everybody. You really can't blame Unity for dropping VSCode support because Microsoft has a reputation of being developer-unfriendly to a ridiculous level, forcing all compatibility work on developers and taking no responsibility.
     
    Last edited: Jun 26, 2023
    florianBrn and TheSleepyKoala like this.
  37. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Microsoft has a very solid developer reputation and in fact has been paying for the full Visual Studio extension just like JetBrains has been paying for the Rider extension. Visual Studio Code is a unique situation because Unity had already made an extension for it and seemed to be maintaining it only to admit later they hadn't been doing it at all.

    See that's the problem. Visual Studio is not an editor. It's an IDE. Everyone seems to want to view it as just a way to edit code and you can use it for that as it has a very powerful editor built-in but that's not the sole purpose of it. It's intended to provide all the tools you need to develop an application.

    It's "heaviness" is just a side effect of it having to provide all of the functionality it's core audience expects.
     
    Last edited: Jun 26, 2023
    Anthiese likes this.
  38. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    JetBrains Rider is a commercial product. They don't pay for it, you do. They handle all the Microsoft pain for a price.

    Microsoft owns C#, VSCode and Visual Studio, and it's not an accident that you can't use any other editor to touch their products, except their own editor, or some complicated third party that costs a hundred a year to maintain due to pain.

    For all I know, Microsoft might be deliberately jerking the VS Code APIs. If there's one company in the world I'd suspect of doing that, let me just say it's not Unity. Cos if people fall off the VS Code tree, they'll fall right into their Visual Studio tree. They might want this to happen.
     
  39. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    What are you even talking about? Do you even know what Rider is? It's literally IntelliJ for C#.
     
  40. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    No, I don't know what Rider is. Last license I paid JetBrains was WebStorm. IDEA and PyCharm I have been using for free.
     
    Last edited: Jun 26, 2023
  41. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    Rider is a completely separate IDE from Visual Studio. Microsoft isn't locking you to their products to use C#.

    https://www.jetbrains.com/rider/
     
  42. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    "Microsoft isn't locking developers to products"

    :D Are you deliberately trolling? Why are you defending them? Unity said they're dropping VSCode support because it's too difficult to maintain, basically accusing Microsoft of this. And you're here to... what? To see that nobody talks ill of Microsoft? Dude.
     
  43. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    No. Unity said they're dropping it as it was never maintained but we were never provided an actual reason. If it were difficult to maintain it wouldn't have been picked up and improved as quickly as @TheSleepyKoala did nor would it have been created in a week.

    Seeing that you don't even know anything about the products you're talking about I'd say that applies more to you.
     
    TheSleepyKoala and Anthiese like this.
  44. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    Don't use your right of opinion to shut down others who like to use this community forum to talk about these matters and to share useful information. I think your comments are only aimed at discrediting both @TheSleepyKoala and me, for no apparent reason.
     
  45. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    You're not sharing useful information. You're sharing an overly negative opinion you don't even have the facts for.

    On the contrary I believe he's done a very good job at maintaining the extension. Your comments are the only ones I have a problem with and even then you're doing a far better job of discrediting them yourself than I would ever be able to.
     
  46. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    What is your argument? I mean, what is the substantial thing you are trying to say to me, apart from ad hominem? Why are you responding to me?
     
  47. Ryiah

    Ryiah

    Joined:
    Oct 11, 2012
    Posts:
    21,175
    I've presented them. You can read them again if you haven't figured it out. I've wasted enough time on this.
     
    AdrielCodeops likes this.
  48. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    Good. Because this thread is currently one of the best Google hits for people trying to survive with VSCode that's fallen out of support, as the original thread post says (and for the reason that Microsoft are not helping them support it). This is the place where people from the Internet land when they're trying to figure out what to do.

    The original thread suggests creating community forks, which is what Koala has done. In my opinion, people should try this fork, because for me it seems to work, and it is a free alternative to Rider and a lightweight alternative to VS.
     
  49. Laicasaane

    Laicasaane

    Joined:
    Apr 15, 2015
    Posts:
    361
    C# (and .NET) is now an open source standard. Anyone can freely develop an editor or IDE that supports C# without paying Microsoft anything in return. Plus, there is also a standard specifies how editors and language servers should communicate with each other, called Language Server Protocol (LSP). Microsoft acts as a curator and main developer for these standards, but they are not blocking anyone from using them freely.

    And before .NET was open sourced, there were Mono and MonoDevelop. At that time Microsoft didn't sue their developers or make life harder for them in anyhow.

    Then, a year after .NET and C# became open source in 2016, JetBrains launched its Rider IDE, which is an alternative and equivalent to Visual Studio.

    OmniSharp is also an open sourced Language Server for C#, made by the community to enable coding C# on any text editor that supports LSP. And if you don't know: it's due to OmniSharp that VSCode can support C#.

    So "Microsoft is locking people to their products" is just an invalid accusation. Compared to 7 years ago, now you have all the choices you could have, but depending on the good will of the community.

    This is wrong too. VSCode is an open source product along with LSP. Microsoft does add their own proprietary features into the version that they distribute. But the core VSCode is always driven by the community. Anyone can distribute their own version of VSCode without paying Microsoft a dime.

    Finally, Unity has never said anything like this. They've just said that they won't maintain VSCode package anymore because all of their efforts are being decidated to the transition to CoreCLR:

    You can blame Unity for dropping support for VSCode. You can blame Microsoft for not supporting Unity on VSCode. You can blame the community for the modernization of .NET that breaks the dated Unity VSCode package.

    But you shouldn't make up fake information then accusing people based on that. I believe that's what @Ryiah was trying to tell to you.
     
    Last edited: Jun 28, 2023
  50. KillDashNine

    KillDashNine

    Joined:
    Apr 19, 2020
    Posts:
    453
    You have your right of opinion, too. But all of youse should just try to learn and distinguish your opinion from fact. Because if you can't do that, you'll get triggered by contrary opinions, because you think your acquired opinion is fact. You should understand that this is a world with many perspectives to the same thing, and it is a part of the mystery and wonder of life to learn to accomodate differing opinions and, also, to meet interesting people that can enrich your world view.

    You accuse me of accusing people. I think you're barking up the wrong tree, it is you and @Ryiah both who have accused Unity for not providing reasons for dropping the editor, without, then, actually trying out and helping to develop the editor plugin community support, but instead blaming Unity for it. Your accusations towards me aren't accurate but I think you have just misread what I wrote, got triggered, and then started responding with your gut.

    I think after you work a couple of more years in this business you start to learn more about different schools of thought with developers and you'll become more tolerant and don't feel the need to attack differing opinions. You might even start to feel that there's something new you haven't learned, and that if you open your mind to alternative opinions, it is not necessarily a crushing experience but you might actually end up learning something new that way, and not just by reading something from the Internet.
     
    hanishojaei likes this.
Thread Status:
Not open for further replies.