Sign in to follow this  
Iderik

C++ or C# for 2D mmorpg?

Recommended Posts

Iderik    142
Hello everyone, I've got an e-mail about me and my teams 2D mmorpg project. We're are using C++ with SDL. He said that C# (with IDE Visual C# 2005/2008 Express Edition) is much better for these kind of projects. That this IDE was designed for students and hobbiests like us. And C# gives much less work and higher performance, also much easier handling with graphics and bitmap classes. And says when we're ready to use multi-playering and hard-accelerated we're avable to .NET sockets and XNA framework (which is relative easy to use). Could you guys tell me if this is correct, and should I leave C++ and SDL behind and start using C# and XNA instead? I'm only interested in 2D games and mmorpgs. Please tell me what you think! Thank you so much for your reply!

Share this post


Link to post
Share on other sites
Toolmaker    967
Quote:
Original post by smr
I would use C#. The Tao Framework enables you to use SDL from C# or any other .NET language.


You're not answering his question. He asked about XNA, not about OpenGL.

On-topic: Yes, I personally say: Go with C# instead of C++. While C++ allows you to get more out of a computer in the sense of performance, C# will increase your productivity, because you no longer have to spend your time doing low-level things. You can focus on the job, and not the utilities to get it done.

I heard good stories about XNA, but I never used it myself so I can't answer there. I did hear tho that redistributing the XNA framework can be a pain in the ass, but esp. for beginners, it's a great library to start out with.

Toolmaker

Share this post


Link to post
Share on other sites
Arelius    196
The biggest thing you must keep in mind if you are planning on using C# + XNA is you are effectivelly limiting the places you can run the code (client or server) to Windows and XBox 360. Now that's you're choice on if that's bad or not.

Indy

Share this post


Link to post
Share on other sites
MaulingMonkey    1728
Quote:
Original post by Toolmaker
Quote:
Original post by smr
I would use C#. The Tao Framework enables you to use SDL from C# or any other .NET language.


You're not answering his question. He asked about XNA, not about OpenGL.

He mentioned that he currently uses SDL -- it doesn't hurt to point out that the decision between languages and the decision between libraries can be somewhat separated. You're the only one to mention OpenGL ;-)

Share this post


Link to post
Share on other sites
TheTroll    883
Quote:
Original post by Arelius
The biggest thing you must keep in mind if you are planning on using C# + XNA is you are effectivelly limiting the places you can run the code (client or server) to Windows and XBox 360. Now that's you're choice on if that's bad or not.

Indy


Why do people make it seem like this is a major issue? I guess if you wanted your game to run on the 8.2% of what is left I guess that would be an issue. Why do people think that because your game will ONLY run on 91.8% of computers that it is any kind of problem? Oh yeah and you get one of the gaming consoles as a bonus.

Sorry, but I am getting very tired of people saying that.
theTroll

Share this post


Link to post
Share on other sites
MaulingMonkey    1728
Quote:
Original post by Arelius
you are effectivelly limiting the places you can run the code (client or server) to Windows and XBox 360.


Wrong wrong wrong wrong

The Mono Project allows C# to work on many more OSes than just Windows.
Jpetrie is also being a devious bastard and playing with C# on the PSP, although that project is admittedly not quite in the mature stages of development.

[Edited by - MaulingMonkey on March 21, 2008 4:56:18 PM]

Share this post


Link to post
Share on other sites
nobodynews    3126
While it is True Mono allows C# to work on other OSes, I'm not sure XNA does as well which I think is what Arelius may have been going for. If XNA is available on other platforms then Arelius is completely incorrect.

Share this post


Link to post
Share on other sites
Boder    938
MM, I doubt we'll see a usable version of XNA on linux. Mono.XNA looks pretty sickly.

TheTroll, the fact is that you can make about 20x as big a splash on linux/mac with a really great free game than getting lost in the sea of windows freeware.

Share this post


Link to post
Share on other sites
asp_    172
If you're doing it for experience in order to later move on into a industry position I would use C++. I'm also fairly sure there is more middle ware for C++ which is either free or fairly cheap. It's a harder decision than what language allows you to be the most productive, the productivity from already tested existing libraries will far outweigh any increase of productivity the language itself provides. If language productivity is paramount I would choose python not C#. Python is also cross platform and allows you to easily outsource performance critical code to C.

Quote:

The Mono Project allows C# to work on many more OSes than just Windows.

People keep bringing this up, but how many Linux users actually deploy mono applications? I know I've never deployed one. This is my mind speaks volumes about what the general view in the Linux community is on .net. People do not like the huge slew of non-free stuff mono is reliant on, there are many legal issues with patents. Mono is fine to deploy on a corporate internal servers, but externally on user computers it might not be as appreciated.

I would LOVE to see some stats of market penetration for .net 2.0 on Linux, MacOS and Windows. If someone knows of a resource I would be very grateful.

Share this post


Link to post
Share on other sites
TheTroll    883
Quote:
Original post by Boder
TheTroll, the fact is that you can make about 20x as big a splash on linux/mac with a really great free game than getting lost in the sea of windows freeware.


Yes, a much greater percentage of linux users would be playing your game, but even with that, you would still have a much smaller over all percentage. A great game will get users no matter what OS it is on.

theTroll

Share this post


Link to post
Share on other sites
px    593
The 'which is better' argument is quite pointless. I would suggest you use whichever you're most comfortable with.

That is all, we now return you to your regularly scheduled programming.

Share this post


Link to post
Share on other sites
Iderik    142
Thank you so much everyone!
I forgot to tell you guys that my goal in programming is to create a 2D tile-based mmorpg. Nothing else, no 3D, just 2D tile-based.

I'm having a very hard decision to make here, but it's leaning more to stay with C++ and SDL.
But no one have mention about C and SDL?

And when I reach the point in my game when I want to make it online multiplayer, is SDL.net a good option? (Havn't read anything about that yet)
And what about the hard-accelerated part?

There is a mmorpg called Frostwinds, and that really got my style in game.
Here is some screenshots:
http://www.frostwinds.com/Screenshots

Thank you again for all the replies! :D

Share this post


Link to post
Share on other sites
jbadams    25677
I would personally choose C# and XNA rather than C++ and SDL for such a project. Either is an acceptable choice, and the points you've listed from the email you received are generally true.

If you have a reasonable amount of experience with C++ and SDL you may be more comfortable sticking with them for now, as familiarity with existing languages and libraries can sometimes be a significant benefit over having to learn something new. Another argument in favour of sticking with C++/SDL would be if you've already done a significant amount of work you do not wish to duplicate.

Share this post


Link to post
Share on other sites
eedok    982
Quote:
Original post by Iderik
There is a mmorpg called Frostwinds, and that really got my style in game.
Here is some screenshots:
http://www.frostwinds.com/Screenshots

Thank you again for all the replies! :D


It's funny you mention frostwinds, as it was made by a member here(Thevenin) and he did it using C# and Managed DirectX IIRC(he did write about how much easier things were in C# in his postmortem if I can ever find it again)

Share this post


Link to post
Share on other sites
Fiddler    860
XNA is great, but you should think a bit more if you are going down that route: is your game going to be free or commercial? I've heard there's a strong shareware market on Mac OS X, which you'd lose if you used XNA.

If you care about that, you can use C# with SDL.Net - this way you get to reuse a large amount of your existing code and your SDL experience.

If you don't care about this, XNA is probably the best choice (mature, well documented, widely used). Tao is another choice, but it's lower level than XNA (thus harder to use). OpenTK fills the gaps between the two - more integrated than Tao, less extensive than XNA, but cross-platform with a focus on simplicity.

Note that everything but XNA is cross-platform - Mono.XNA sadly looks dead.

My advice: *definitely* move to .Net, not only will you be more producive, but you will *enjoy* the project more (don't underestimate the importance of this). I won't try to tell which library to use (I'm developing OpenTK so I've obviously made my choice :)) - you should weight the pros and cons of the above choices and take your pick.

Share this post


Link to post
Share on other sites

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