I’d like to use VSCode as an editor for my Monogame project, but currently fail to get it to work. I found a posting here in the forums that explains the setup for Linux, which I tried to follow, but still it won’t work.
I have installed .NET Core and created a console application. I can even build the project both from the command line and from VSCode.
However, it crashes when I try to run it because it doesn’t find some files it needs.
I installed MonoGame.Framework.WindowsDX from nuget, in this case, System.Windows.Forms cannot be found. I tried to also add it to the .csproj file, which downloads an appropriate package from nuget, but this didn’t work either.
With MonoGame.Framework.DesktopGL, some SDL-related dll is missing.
Any idea on how I could solve these problems?
MonoGame.Framework.WindowsDX. You also mentioned that you’re using .NET Core and Linux if I read it right.
Well, the WindowsDX distro of MonoGame is…well…as the title entails… only for Windows’ DirectX. If you plan to do Linux, you want
MonoGame.Framework.DesktopGL. This distro of the framework is for Mac OS, Windows and Linux.
Also, the reason it can’t find
System.Windows.Forms is because .NET Core does not have Windows Forms - like, at all. You’d have better luck with Mono, but, as I said, the WindowsDX package is only for DirectX on Windows and if you’re developing for Linux…you won’t have DirectX in the first place.
Thank you for your reply. I’m sorry if I was unclear about which system I use, but I’m not using Linux, but Windows.
The DesktopGL package doesn’t work either, I get an DllNotFoundException for SDL2.dll when I try to run the project.
I was able to solve the problem by using this nuget package
instead of the one I used before. This one seems to include the necessary dlls.
My project still doesn’t run, but now it fails because it doesn’t find the sprite resources, which is probably because of modifications to the directory structure.