Jump to content
  • Advertisement
Sign in to follow this  
Ned_K

[.net] Make the case please...

This topic is 4826 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Why would I want to make a game under the auspices of .net? I have little experience with it and am curious what the people who use it actually think. I didn't see this answered in the FAQ so I'm just posing the general question. What REAL, measurable advantages does it gain me?

Share this post


Link to post
Share on other sites
Advertisement

.NET is...

* A Marchitecture. In other words, the name is applied to a whole rake of different, but related, technologies, not all of which are necessarily relevant to your needs.

* A Platform. You don't write for "Windows" any more; you write for the '.NET Platform'. ANY operating system with a working implementation of the .NET runtime could, in theory, run your game. Thus .NET is also...

* An Abstraction Layer. The .NET Common Language Runtime is similar (in a superficial way) to Java in that it hides the underlying operating system and hardware from you, the developer. It means you no longer need to think about optimising for _either_ an Athlon64 CPU or an Intel CPU or even a VIA Eden flavour of CPU. In future, you could even (theoretically) find your software running on a MacIntel box.

* A bloody massive improvement on the archaic Win32 architecture. Win32 (and its immediate ancestor) still retains elements of its Pascal heritage. (Yes folks, early versions of Windows were written in Pascal, not C. This is why some older functions require you to jump through strange argument-passing hoops.)

* A much more elegant framework compared to the hack-job that was MFC. MFC was an attempt by Microsoft to slap a C++ object-oriented layer on top of Win32. It sort-of worked, but since the C++ compilers of the day were still less than mature, it means MFC has built up a legacy of crap that makes it rather more painful to work with than one would expect.

* Language-neutral. As long as you can find an MSIL compiler for your preferred language, you can use that language. C# is touted as the successor to C++ for Windows application programmers, but that doesn't mean you _have_ to use it.


From a game development perspective, .NET is a bit of a mixed bag. On the one hand, all the points above are great if you're only targeting the Wintel platform. However, .NET is also...

* a Work In Progress. .NET has effectively been a public beta for some years now. It works, but it's still not... quite... finished. The next (2005) iteration will probably the first release of the toolchain that can truly be considered "ready for primetime".

* Not Available On Consoles. This might not be a problem for many indie developers, but for anyone looking to break into mainstream games development, it's a gigantic woolly mammoth of a stumbling block. Even Linux support is iffy at the moment.


Make no mistake, .NET _is_ the future of Windows application development. However, we won't really see it take off completely until Windows Vista hits the streets next year. And even then, it'll take a little longer still before C++, Win32 and MFC are nothing more than a story used to scare your grandchildren.


To be brutally honest, .NET isn't relevant to games development. Middleware solutions are already replacing the need to know about the underlying hardware. RenderWare, NDL Gamebryo and Auran's "Jet 2" platforms really _are_ platforms: you don't need to worry overmuch about the hardware until you get to the point where you need to look at the game's 'chrome': i.e. the platform-dependent GUI elements, such as loading/saving games to memory cards and all that twaddle.

.NET will probably be quite popular for developing tools for development purposes, but it's unlikely it'll be a massive part of any game developer's life in the near future. The mainstream PC games market is pretty much falling apart now. It's a market increasingly dominated by a myriad casual games and only a handful of mainstream FPS and sim franchises.

Regards,

--
Sean Timarco Baggaley

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
For Tools development .Net is the greatest thing since sliced bread(without the pastrami of course).

Share this post


Link to post
Share on other sites
.Net + Pastrami... mmmmm (actually drools)


"Why would I want to make a game..."

1) You will be able to focus more on writing your game than tracking down memory related bugs; Programs which use the .Net framework for memory allocation reap the advantages of a (imo) very freaking smart garbage collector.

2) Your game could be portable without recompiling the .EXE (depending on what middleware you use and whether you use inline assembly).

3) If you use C#, you get a significant reduction in code you have to maintain (you eliminate the need for separate header files), and you get a significant reduction in compile times (because there is no nasty deeply nested #including going on). You don't have to use C# if you have some personal grudge against it, though.

4) .Net reflection capabilities can allow you to get intellisense-like information even if you're not using Visual Studio (you could even retrieve this information from within your program itself). Might not be that important to most people though. C#'s intellisense in VS2003 and 2005 is better than anything I've used for C++ ever.

There are more... I always say "the best way to know how something works is to use it, break it, and take it apart."

Share this post


Link to post
Share on other sites
I have to admit, I love C#/.NET for normal program development (especially GUI tool development compared to really painfull older technology like MFC) ...

I don't use it for actual game development, for that I still use C++/OpenGL/OpenAL ... or C++/DirectX ... although I have begun considering C#/Managed DirectX ... I just don't see the point (standard C++ is the BEST langauge for modeling complex problems ...).

Share this post


Link to post
Share on other sites
I use .NET for everything I do: work, game development, tool development, etc. I use a variety of languages to get the job done including C#, VB.NET, Boo, and soon: Nemerle!

I love the .NET class library; much more thought out and complete than any other I've used.

I disagree that C++ is the best language to model complex problems. It all depends on the problem, of course, but I find that mixing the details of the problem with the details of the machine your programming for take the focus off your problem. If you have to deal with memory management or other nuances of C++, it's harder to think about what you're trying to accomplish.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
I am an .net addict too ;)


Why you should use it?

Have you ever finished a game?

With .net chances are a lot higher than without. It is hard to believe but it is realy impressive how much you speed up development.

If you can't finish a .net project you won't finish any project.

Share this post


Link to post
Share on other sites
Here's my list of reasons for liking C# with .Net.

1) No Headers: I occasionally have to do c++ work, and headers are just a redundant, aggravating step to adding a simple class.

2) Project organization: C# projects are organized by namespace in the same way that Java does. The folder hierarchy is a boundary between project modules, and it really adds clearity for where things should go. C++ projects can use the same format, but generally the IDE just plops everything in one folder. You must put forth a lot of extra effort to do the same thing as C#.

3) System.Collections: This is a namespace that holds hashtables, lists, sorted lists, etc... It is much easier to code with these as compared to the C++ standard template library.

4) Rapid prototyping. Visual Studio has a great drag and drop Form editor that puts the MFC resource structure to shame.

5) csUnit: Nice for unit tests. I use this as a tool for testing religiously.

How productive is it? Well, we have finished 2 published titles in 18 months (Tin Soldiers) and we are now working on a 3rd. We have developed at least 4 or 5 editor type tools using it. I have to admit, I have become a fanboy for the .Net.

[Edited by - mbelew on September 26, 2005 2:15:48 PM]

Share this post


Link to post
Share on other sites
Quote:
Original post by mbelew
2) Project organization: C# projects are organized by namespace in the same way that Java does. The folder hierarchy is a boundary between project modules, and it really adds clearity for where things should go. C++ projects can use the same format, but generally the IDE just plops everything in one folder. You must put forth a lot of extra effort to do the same thing in C#.

not entirely true. C# namespaces are not tied to the directory structure, unlike Java. C# classes can be in completely seperate folders from what their namespace indicates. The IDE will automatically insert namespace text to reflect your directory structure, but it's not necessary.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!