Sign in to follow this  

XNA vs. C++ for serious game programming

This topic is 3844 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

Hi everyone, I'm a college student learning for BSc in computer science. So far I've been learning C# and I plan to do the "Windows-based client development" and "Application development foundation" exams in this summer. We have mandatory courses at school in C# which is good because C# is a very good language for enterprise application development. However I've read everywhere that game development is being done in C++ and I couldn't find any jobs for .NET (or C#) game developers so it must be true for now. I'd like advice from you if I should learn XNA or C++ if I want to become the part of a bigger team and develop commercial games later on. I didn't decide which way to specialize in game programming yet, and I've read that I don't have to hurry with that until I got my first job. I think I don't have enough enthusiasm to be a graphics programmer, they usually wake up and go to sleep with graphics and that's not true for me. I didn't use XNA at all, but if it's really based on .NET 2.0 then it must be somewhat convenient to use. The problem with it is that it's too high level and that could mean too much restrictions. So should I think of C# as a language that was a good tool to learn object oriented techniques, but neglect it from now on and go C++ all the way (because C++ is huge and needs full attention) or go deeper into C#, .NET and XNA? I have 2,5 years left from college and when I finish I'd like to move to England, so it's somewhat important for me to have a knowledge that can be put to broader use in the video game industry. (I've read all about how I should work on extra projects and get experience working with people, so right now I'm only concerned about the topic in question.) Thanks in advance for the responses.

Share this post


Link to post
Share on other sites
Well I would say you have a number of ways to look at it. On one hand yes C++ has a lot of history, support, and control you won't have using XNA. Using XNA will also gloss over large sections of knowledge you may find useful.

On the other hand if you have little to no past in writing games XNA can get you into the game (so to speek) and let you learn a lot of conceptual ideas and logic very quickly, which is what it was created to do. All using a C# which you already know. As I bang my head against the wall today looking for the source of a memory access bug that has haunted me for months, I'm left wondering if I would even be having the issue had I used C#.

Share this post


Link to post
Share on other sites
Quote:
Original post by Goober King
Well I would say you have a number of ways to look at it. On one hand yes C++ has a lot of history, support, and control you won't have using XNA. Using XNA will also gloss over large sections of knowledge you may find useful.

On the other hand if you have little to no past in writing games XNA can get you into the game (so to speek) and let you learn a lot of conceptual ideas and logic very quickly, which is what it was created to do. All using a C# which you already know. As I bang my head against the wall today looking for the source of a memory access bug that has haunted me for months, I'm left wondering if I would even be having the issue had I used C#.


I see what you mean, to see the large picture, XNA is useful. I can use it to see how some things are done. Ultimately though it fails to provide the freedom (to write a buggy application :)) that C++ does.

Btw you didn't use C# because you didn't have a choice, right? I mean the automated garbage collection in C# is algorithmically extremely complicated and provides the best way to free up memory, but when it comes to a concrete implenetation where every millisecond counts, then you know best when and how to free up memory to keep the game fluent. Or you chose C++ over C# for some other reason?

Share this post


Link to post
Share on other sites
Check out http://www.xnaracinggame.com/
Is that serious enough for you?

XNA Racing Game runs silky smooth on the Xbox 360 despite being somewhat unoptimized and utilizing only a single thread (XNA allows you to use up to 4 of the 6 hardware threads from the 360's 3 cores).

Professionals and hobbyists alike are discovering the magic of XNA. Hobbyists are producing amazing results with limited experience and professionals are building prototypes and casual games in a fraction of the time and at a fraction of the cost of using C++.

Jump in: http://creators.xna.com

Share this post


Link to post
Share on other sites
Hi;

No doubts about it, my advice is C/C++ if you want to become a programmer for a big team. And also you can keep studying C#.

For game programming you have two great libraries among others, DirectX an OpenGL.

XNA is a good framework and it's community is growing. Take a look in their FAQ to know it better:

XNA Frequently Asked Questions

One good question is this, and I quote it:

Quote:
Q: Can I use the XNA Game Studio Express or XNA Framework to build a commercial Xbox 360 game?
A: XNA Game Studio Express lets you create Windows and now Xbox 360 console games much more easily. These games are limited to non-commercial scenarios for 360 titles created with XNA Game Studio Express. However, XNA Game Studio Express may be used to create commercial games which target Windows. We plan to release XNA Game Studio Professional next year which will allow developers to create commercial games for the Xbox 360 in addition to Windows.


So, which type of licence will have the XNA Game Studio Professional and how much is gonna cost? I think we'll have to wait to see it.

Share this post


Link to post
Share on other sites
Quote:
Original post by szolDat
Quote:
Original post by Goober King
Well I would say you have a number of ways to look at it. On one hand yes C++ has a lot of history, support, and control you won't have using XNA. Using XNA will also gloss over large sections of knowledge you may find useful.

On the other hand if you have little to no past in writing games XNA can get you into the game (so to speek) and let you learn a lot of conceptual ideas and logic very quickly, which is what it was created to do. All using a C# which you already know. As I bang my head against the wall today looking for the source of a memory access bug that has haunted me for months, I'm left wondering if I would even be having the issue had I used C#.


I see what you mean, to see the large picture, XNA is useful. I can use it to see how some things are done. Ultimately though it fails to provide the freedom (to write a buggy application :)) that C++ does.

Btw you didn't use C# because you didn't have a choice, right? I mean the automated garbage collection in C# is algorithmically extremely complicated and provides the best way to free up memory, but when it comes to a concrete implenetation where every millisecond counts, then you know best when and how to free up memory to keep the game fluent. Or you chose C++ over C# for some other reason?


I'm more of a programer by force than by DNA if you will. I learned C like 15 years ago and never really learned anything new along the way. Then there is the fact that I started the game like 3 1/2 years ago and had never heard of C# . Been thinking of tinkering with it latly but haven't done too much. Have looked at the Racing demo and all but there are some minor syntax questions I have and the 100% pure class thing I've found very hard to follow flow wise.

Anyway that "Big picture" you speak of is really really importaint. You can't make game without it and nobody would want you if you didn't have a good idea how everything works together. From there if you find an area that intrests you then you can always dig in and learn more about what is behind it.

At this point there is no way one person can know and write everything involved in game making. The field is too big and each area has kind become its own thing. Sometimes people focus on one area and gives the rest of us something wonderful to use ourselves. All that lowlevel stuff is dauntingly huge and for the most part redundant.

I say learn to program well and lean how games are made. From there you can move onto whatever tickles you the most. XNA may not be the most low level or portable solution but you can get bigger faster payoffs to keep you motivated. That makes for a good leaning tool.

[Edited by - Goober King on June 2, 2007 7:37:39 PM]

Share this post


Link to post
Share on other sites
Well, I've previously done a bunch of game programming with C++ and used C# for a bunch of other stuff. If you're just comparing C++ to C#, use whichever you feel like. You can make great games with either. In terms of what is used in the industry, it's currently C++. I don't think that's going to change within the next few years, though it make further into the future. But I've seen C# used for tools, which has more to do with the ease of developing a UI in .NET than anything else. Plus, tons of research has shown that C# is in the same ballpark for performance as C++. It might not be quite as fast but generally unless you're trying to write something really high performance, it won't matter.

However, XNA is a bit of a different beast. It REALLY simplifies getting stuff up and running for a game. I mean, compare the beginner samples in DX9 with C++ to the XNA ones.

Bottom line, I'd recommend XNA. It will simply allow you to actually create what you want much more quickly if that's your goal. On the other hand if you want more industry related experience, maybe C++ is the way to go but it'll take you a lot more effort to get stuff running.

tj963

Share this post


Link to post
Share on other sites

This topic is 3844 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.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this