Jump to content
  • Advertisement
Sign in to follow this  
Corrob

C# and XNA vs. C++ and SDL

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

Hello, this is my first time starting a post. So far I have learned some C# and some C++. I was wandering should I stick with C# and learn XNA or go with C++ with SDL.

Share this post


Link to post
Share on other sites
Advertisement
Whichever you prefer. Neither one is better or worse than the other.

I recommend C# and XNA for a number of reasons. First having the garbage collector makes beginning game programming (and even intermediate level) much easier. A lot of that helps you then learn a lot of graphical and gameplay-related programming topics that are, in my opinion, trickier to learn in C++ if you are not very experienced.

Platform availability is also a big difference between the two of those. With XNA you can make games playable on your Windows PC and your Xbox 360. With SDL and C++ you can make games for Windows, Linux, and Mac OS X.

Share this post


Link to post
Share on other sites
Thank you very much for your reply.

From what you said I think I will go with C# and XNA because I am not experienced. I still welcome other peoples replies. Thank you.

Share this post


Link to post
Share on other sites
I agree with NickGravelyn and recommend C# + XNA since you're saying that you don't have much experience with either C# or C++. C# is a lot easier to get started with and do some productive things when you're starting out compared to C/C++.

Share this post


Link to post
Share on other sites
Well, I thought that I would just post my two cents here.

C++ isn't nearly as hard to learn as a lot of people claim it is. It may not be the easiest language to learn, but it is certainly very versatile. On top of that, you can find tutorials on C++ (and SDL, to a lesser extent) anywhere. There is simply a really large number of programmers that know it. So it is a bit harder, but it was my first programming language, and I'm doing just fine.

As for SDL, I'm only just starting it, and I absolutely love it. When they say Simple DirectMedia Layer, they put the emphasis on Simple. No joke, SDL is really easy to pick up.

Now, I have never used C# or XNA, so I can't say that C++ and SDL is a better option, but I can tell you that C++ and SDL makes a really good option. And somebody had to show some love for the other side on this topic.

Brian

Share this post


Link to post
Share on other sites
Quote:
Original post by shou4577
Well, I thought that I would just post my two cents here.

C++ isn't nearly as hard to learn as a lot of people claim it is. It may not be the easiest language to learn, but it is certainly very versatile. On top of that, you can find tutorials on C++ (and SDL, to a lesser extent) anywhere.


i'll have to agree, i mean i'm far from an expert but i didn't have much trouble at all getting used to C++, i'm not saying C++ is better, because from what i gather what language is best depends on the situation, but the difficulty of C++ seems to be greatly overstated.

i've been programming for 8 only months or so and i've put together a handful of 2D games using C++ w/ SDL. that being said, i don't know much about C# other than dabbling in it from time to time.

everyone has a bias, ie. for everyone who pushes for C#, you'll notice that its the prefered language of that person, and the people who are really familiar with a bunch of different languages tend to be the ones who tell you to just choose one and stick with it.


Share this post


Link to post
Share on other sites
Hello,

Most people, who have been game programming for a while, would recommend for you to either start with Python or C# and I would second their opinion. Both Python and C# are easier for beginners to start off with. They both have ways to make graphical games and that is Pygame(for Python) and XNA(for C#). I have never used Pygame before so I can not vouch for that, but I have used XNA before. XNA is x100 easier to learn than SDL, DirectX, or OpenGL in my opinion.

I would recommend you not to learn C++ first. Trust me on that because I actually learned it first. C++ is a monster language to try to learn first. Both C# and Python will teach you how to program without worrying about a lot of crazy things. One of those things is garbage collection, which is hard to make sure you do properly.

Anyways choose either Python, C#, or some name language on your own choice and make sure you learn the language first and then learn either Pygame, XNA, or what ever graphics thing for the language you chosen. Then start programming games, and when you are ready you should delve into the vast realm of C++ but that is only when you are ready. Anyways I wish you much luck with your programming experience and hope to see some of those games :)!

~Sincerely,
Carl J. Loucius

Share this post


Link to post
Share on other sites
I don't know C#/XNA, but I've hacked up a pretty simple engine in C++/SDL/OGL. I wouldn't do it again, even though I am now decent with C++ (1 yr professional experience). You just spend far too much time debugging memory issues, even as an intermediate-level developer. Jump into a managed language and you no longer have to worry about stuff like that - you get to spend your time writing logic, and not wasting entire days debugging crap that you don't care about.

Debugging is not fun. Writing code is fun. Writing code in C++ means more time wasted on the frustrating, boring part of programming.

Share this post


Link to post
Share on other sites
Well if you want to be making games right away stick with C#/XNA.
It's way easier than C++/SDL but not as easy as Python/pygame.

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!