What is the best language for game programing ?

None of the ones you mentioned :D
C++ - speed. All of todays commercial games are written in c++.
 
mutant means speed as in running speed not development speed. C++ is very time consuming and frustating.
 
i use 3D GameStudio... It has C support too.
definitely c++ rules but Gamestudio may cater your needs...
 
If your looking for speed, use VC++ NONMANAGED code. This means, if your using VC++.NET, make sure you are not using managed code, or you will not get the speed you need for a 3D game.

If your not making a 3d game, aka doing 2d or "5d", vb6/.net or c# is more then adequate for coding.

If your planning on making money from your game, stay away from all of the .net scripting languages (aka, all .net languages), unless you want your source code shown to the world :)
 
Shannara: .NET languages are _not_ scripting languages.

Managed code is somewhat more vulnerable to reverse-engineering than non-managed code, but its not like youre giving it away. If youre that paranoid, get a code obfuscator.

3D games certainly need unmanaged C++ (unless your gamers all have lightning machines :) ). For all other games, I would recommend .NET languages simply for shorter development times.

Ive heard a lot of great things about DirectX 9. Since anyone whos asking the question "What is a good game programming language" is obviously at square one, you may want to play around with this just for fun.

.steve

PS: I dont recommend writing a game in VB6. I did this in high school, and its disgusting. Learn a real programming language.
 
I wont argue about the "best" language to use - its pointless. Instead, since youre obviously new to programming Id suggest either C# or VB.NET as the best language for you. Theyre much easier to pick up than C++ (managed or not) and you dont have to start with DirectX, which is difficult by itself even if youre really good at programming (regardless of language).

Id play around with pictureboxes and learn the language first, then move onto some GDI+ functions (for painting 2d pictures around the screen). Then move onto 3D if it suits you - this will probably be a few weeks/months depending on your investment in time and patience.

-Nerseus
 
Thats true. If youve never even done anything with graphics before, GDI is certainly easier than DirectX. Getting an understanding of how to mess around with device contexts and drawing functions is a definite must.

If youre serious about game programming, though, youll need to learn DirectX (or OpenGL) at some point. It sounds like Managed DirectX makes things much easier - compared to the DirectX of the past. If youre adventurous, dont feel like you cant jump in the deep end. But expect to swallow a bit of water on a topic as difficult as DirectX. And expect to be in there for many moons before you can swim. :)
 
*tosses in his nickle of advice*

The absolute best language for game programming is a toss up between C and C++ (Im not talking about .NET here, Im talking about unmanaged C++).

HOWEVER! If you are new to programming, then starting off with C# is probably best. (yes, C#, starting off in VB will only make the transition to C/C++ harder if you want to write a serious 3D game later down t he road). If youre not new to programming and consider yourself intermediate, then just use C or C++.

What you really need to do is start off with a really simple game, such as tic-tac-toe or something using GDI+ (or picture boxes I suppose if youre really THAT new), that way it gives you the basic idea of how to load and use graphics, and a little about AI. Then move on to say, Tetris, so you can learn about the game loop and player interaction with moving objects. After that some funky 2d game of your own creation, then youre probably ready to move on to DirectX and simple 3D stuff. Down the road, if you become serious about gaming, youll want to start making the transition to C or C++.

EDIT:
And to actually answer your question, C or C++ (unmanaged) is best because of pure speed and total freedom with what you can do.
 
I agree with wyrd, C and C++ is the best choice. I was big time into graphics years ago and used C, C++ and assembler to create a snazzy space invaders type game, pity I never finished it! I also used these to create image file viewers, jpeg, gif etc.
 
From Microsofts DirectX Site

Benefits of Managed DirectX

By eliminating the Component Object Model (COM) interoperability layer, Managed DirectX improves performance. Managed code can reduce the volume of code and increase productivity. The interface is more intuitive, inheriting from the powerful and easy-to-use Microsoft .NET Framework common types. Managed code also frees you from having to deal with most memory management tasks, such as releasing objects. In the SDK you will find managed Visual Basic .NET and Visual C# samples and tutorials that duplicate nearly all of the unmanaged code samples.
 
As far as pure speed unmanaged C/C++ will of course win. However, if the majority of the program time is spent on something like Direct3D calls then after the first call C# and VB come very close in speed. Some Direct3D speed tests actually indicate that C# gets an overall higher framerate than C++, and I believe Microsofts prediction was 98% of total speed compared to C++. If you need every last percent then C++ is the way to go, otherwise you most likely wont be able to tell (other than possibly startup time). C# is much easier as well, I know C++ but after using Managed DirectX 9 I refuse to go back to it unless Im trying to render millions of polygons or something.

Or you could use one of the languages I currently have in development :)
 
Dont get me wrong, I love .NET. However I refuse to just believe pure hearsay about how C# is equivalent (or close to) in speed to C++. Biased comments from the Microsoft site isnt something I tend to believe either as theyre trying to sell their product.

What Im trying to get at, is this; If you are going to say that one language is equivalent (or close to) in speed as another, you need to provide us with some proof. A link to a web site, source code of your own benchmarking, your own article written up in about the insides of both languages and why it is so, anything.

Whether realizing it or not, the worst thing one can do is provide faulty information. I would personally love to see undisputable proof that C# can compete with C++ in terms of speed.

Stopping for a second and reading what Ive just typed, I realize that my comments may seem harsh or rude. They are not intended as such, and I am not attacking anyone.
 
I doubt any .NET language can compete. However, I believe C# as a standard will most likely be available outside of .NET; I think Borland is doing an implementation of it or something.

C# and C++ are completely different languages; the only thing the same is the syntax.
 
C# Builder...lol

Anyway :), I will not belive that C# can come this close to the speed of C++, give me all the proof you want and I wont believe until I do it on my own :p.
 
.NET code can beat C++ code when it comes to raw number crunching because of JIT optimizations performed on the code for the specific processor the code is running on.

To satisfy my conscience for saying this, I just created two tests - one with C++ and one with C#. In the test I run a loop 2 billion times, each iteration increasing another integers value by one. I turn off optimizations (which would stop such a pointless loop from running at all) and these are the results:

C++: 10.405 seconds
C#: 10.044 seconds

And they say JIT compiled code is slow.
 
I didnt say that that code is slow :).
Ok, I did the same test, now I believe, :rolleyes: , enlightment. :p
Funny that I didnt do this kind of test before :)
 
The reason .NET programs are generally slower than their C++ counterparts is not because of slow executing code, but because a lot of .NET is still a wrapper to win32 functions. This wont always be the case though.
 
Back
Top