Live data from Hacker News

What's new in C# for Godot 4.0

godotengine.org

31–40 of 112 posts

Re: What's new in C# for Godot 4.0

#31
post #5
post #2

„ we now use the .NET SDK to embed the .NET runtime. This means we use the CoreCLR runtime for desktop platforms” Wow this is huge! Seems like Unity is lagging behind and their journey for CoreCLR just started.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

They use their own heavily optimized Mono runtime that is .Net Standard 2.1 compliant and supports all C# 8 and many C# 9 features.

As a C#/.Net developer I'm satisfied with the C# and .Net support in Unity. The pain points are elsewhere.

https://docs.unity3d.com/Manual/dotnetProfileSupport.html

https://docs.unity3d.com/Manual/CSharpCompiler.html

Re: What's new in C# for Godot 4.0

#32
post #2

„ we now use the .NET SDK to embed the .NET runtime. This means we use the CoreCLR runtime for desktop platforms” Wow this is huge! Seems like Unity is lagging behind and their journey for CoreCLR just started.

Hobbyist unity dev here. Can anyone explain the mono/coreCLR commentary in this comment thread? I recently learned that mono works kinda like an interpreted language. This makes sense I think because the internals of unity run C++ code; the C# code is just an interface into the C++ parts of the engine. I haven't done a deep dive into .net ecosystem ever. I probably should at some point. Since I only work in unity and…

Mono and coreCLR are two alternative implementations for .Net runtime. Just like Firefox and Chrome are two implementations for various web formats, or CPython and PyPy for python language and many other examples.

Note in this comment I might be slightly imprecise with the use of naming since the specification, standard library, runtime can be separate projects each with its own name. But often multiple of those parts are made by same people so it can be a bit confusing especially with the way Microsoft names them with various capitalization.

Mono started as open source implementation of .Net and means to run C# on Linux when the Microsoft implementation of .Net was fully closed source and worked only on Windows. At that point it made sense for Unity to use whatever open source implementation of .Net they had access to which was mono. Years have passed and a lot of things have changed. At some point Microsoft bought Xamarin(the company that is main contributor/maintainer for mono project).

On the other side coreCLR is latest implementation of .Net from Microsoft. Unlike earlier versions of .Net from Microsoft it is open source and compatible with Linux and macOS.

As with many languages one of the implementations (the one made by inventor in this case Microsoft) is the leader, while others are playing catch up both in terms of new language feature support and also quality and tooling. Such situation is hard to avoid because developers of one implementation are making whatever they want while being sponsored by big company. While the others are trying to implement something that's more or less compatible with leader while having much smaller budget.

In the early days mono at least had the benefits of being open source and crossplatform compatible. Now they have lost this advantage. Even worse, the main contributor of mono is owned by Microsoft so there is high chance that they will slowly kill it in favor of their own implementation. Since the coreCLR is the primary implementation made by Microsoft it will more likely have much better integration and compatiblity with all the developer tooling made by Microsoft (Visual Studio, debugger) , better compatiblity with various third party .Net libraries, better support for new language features.

Re: What's new in C# for Godot 4.0

#33

Any godot programmers here. How is godot's support of games in the browser? 4 years ago I was deciding on a game engine to use. I considered it to unreal, Unity, and godot. I want to be able to build games that can be played on the web. I have many fond memories of the Flash game days. Distributing games over the web allows me to share games with people without the friction of installers, or App Store gate keepers, w…

I have written a few games in Godot, which also work in the browser for Ludum Dare. [1] Works great, 2D and 3D, with small differences, but I can only speak for GDscript. I'm not sure if C# exports are working.

First and foremost: Build time for all export targets together (windows. linux and web) takes less than 10 seconds and usually just work.

Some things like GPU particles had to be replaced with CPU particles and I remember that some texture compressions were not properly supported. But other than that, it mostly works out of the box. Can only recommend.

[1] https://ldjam.com/users/zubspace/games

Re: What's new in C# for Godot 4.0

#34

Any godot programmers here. How is godot's support of games in the browser? 4 years ago I was deciding on a game engine to use. I considered it to unreal, Unity, and godot. I want to be able to build games that can be played on the web. I have many fond memories of the Flash game days. Distributing games over the web allows me to share games with people without the friction of installers, or App Store gate keepers, w…

It has been excellent, best browser game engine imo - however as of Godot 4, the web export is completely broken, unfortunately. Godot with C# straight up has no web export and no mobile export atm, just desktop.

Re: What's new in C# for Godot 4.0

#35
post #5
post #2

„ we now use the .NET SDK to embed the .NET runtime. This means we use the CoreCLR runtime for desktop platforms” Wow this is huge! Seems like Unity is lagging behind and their journey for CoreCLR just started.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

They have to use Mono. New .NET Core Runtime does not yet support all platforms that Mono used to support, and won't for a while.

Re: What's new in C# for Godot 4.0

#36
post #5
post #2

„ we now use the .NET SDK to embed the .NET runtime. This means we use the CoreCLR runtime for desktop platforms” Wow this is huge! Seems like Unity is lagging behind and their journey for CoreCLR just started.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

CoreCLR is not built for game, the fork from Unity is so there is little chance that CoreCLR is faster.

Re: What's new in C# for Godot 4.0

#37
post #36
post #5

Earlier quoted context omitted.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

CoreCLR is not built for game, the fork from Unity is so there is little chance that CoreCLR is faster.

What are the specific requirements for games? C++ is also not built for games. It’s built for anything, including games.

Re: What's new in C# for Godot 4.0

#38
post #36
post #5

Earlier quoted context omitted.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

CoreCLR is not built for game, the fork from Unity is so there is little chance that CoreCLR is faster.

This is not correct, as can be readily proven to yourself by measuring.

Re: What's new in C# for Godot 4.0

#39
post #35
post #5

Earlier quoted context omitted.

Unity is still using Mono? The CoreCLR should easily perform twice as good as Mono in many cases.

They have to use Mono. New .NET Core Runtime does not yet support all platforms that Mono used to support, and won't for a while.

You can use mono for targets that need it and .NET 6 for those that don't

Re: What's new in C# for Godot 4.0

#40
I started learning Godot 3 a while back, however Godot 4 seems very promising, especially because of the built in LOD support, which feels ahead of even what Unity provides (since these would be automatically generated, a bit like in Unreal): https://docs.godotengine.org/en/latest/tutorials/3d/mesh_lod...

Now, Godot 3 still had a plugin for similar functionality, except for the automatic generation (so close to being on par with Unity in that regard), I even ported it over to C# in private: https://blog.kronis.dev/articles/porting-the-godot-lod-plugi...

However, while the older version might be more stable for now, such as having mobile and web export, it's also pretty clear that migrating to the newer one once it comes out will actually be a good idea, also because of the new improved 3D rendering in general.

Post reply on HN