What languages to learn for Game Development?

  • Thread starter zeion
  • Start date
  • Tags
    Game
In summary, There is no one-size-fits-all answer to this question, as the type of game you are making and the skills you have will determine the relevance of specific languages. However, knowing a C++ or a scripting language may be useful for game development.
  • #1
zeion
466
1
Hello,

I was just wondering what kind of language I should learn for getting into game development?
I'm currently working through some pygame tutorials. Is that relevant at all?

Thanks
 
Physics news on Phys.org
  • #2
There's not really a good answer to your question. C++ is most likely to be relevant. Java, or C# might be useful. Lua might come in handy. Knowing how to program is far more important than what particular languages you know.

Btw, you might get a lot more information if you look at the forums on gamedev.net or something.
 
  • #3
Is Python not as relevant in the professional world as C++? Sorry I'm a newb to this.
 
  • #4
C++. Python is a great language, however your question was specifically for game development, of which in my limited understanding would be best served by C++ and a knowledge of OpenGL.
 
  • #5
zeion said:
Hello,

I was just wondering what kind of language I should learn for getting into game development?
I'm currently working through some pygame tutorials. Is that relevant at all?

Thanks

It depends on what type of game you are trying to make. I used to involved in game development as a programmer and my comments come from those experiences.

Most games are very resource intensive. Most game engines have the goal of producing good visuals and sound, with a game that is as responsive as possible, and has a design that allows people to create a game as fast as possible with design decisions and implementations that make the above a reality.

Most decent engines provide a completely data driven and script driven system that has specific routines and data definitions that are directly tailored for games. The game engines usually provide a scripting system that is usually event driven and has a syntax usually along the lines of a modified C/C++ language or Java.

If you want to use an existing platform (Unreal, Doom, Quake, Torque etc), then it's likely that you will just need to get the SDK and start writing scripts, exporting models and level maps, and editing text files with a text editor.

If you want to modify (or create your own) existing engine, C++ is the way to go.

Because games are so resource intensive, a lot of the code is written not only in C++, but also in an assembler language of some sort: math routines are written in SIMD instruction sets like SSE2, shader routines are compiled to assembly routines that GPU's read and other routines use very optimal C++ routines that may even take advantage of specific platform execution environments.

With a game engine there are a lot of things to understand.

Scripting languages require compilation and interpretation. If you want to effectively unify the script environment with the C++ environment, you need to create base class design with a lot of metadata to do this effectively. Compilation requires compiler design theory.

Graphics is also a big thing. Back in the quake days people used to write their own triangle rasterization routines, but nowadays we just make a few OpenGL or DirectX calls. But even now with that done for us, its more complicated in different ways. Graphics cards have very extensive vertex and fragment pipelines complete with a complexity of options. You will have to learn all about this for any kind of 3D rendering.

If you want a GUI like that in Doom 3, you can do this by using your graphics routines to render to a texture. On top of that you will need a framework for UI, and you need to factor in design decisions with standard UI design to create the appropriate framework. Not easy by any means.

Then you've got optimizations. You optimize for rendering by using spatial classification systems (BSP trees, portals, octrees, and so on). You optimize the rendering pipeline (static vs dynamic objects), physics (collision detection), game play (hit tests), and others.

Now you have take all of this (and more) and figure out a way how to design it in such a way that its flexible and fast and allows you to create games pretty quickly while still giving good results.

Also I didn't even mention the whole networking thing: many professional engines design themselves around network communication. The client/server architecture is a centerpiece of the design not only to make multi-player capability optimal and to allow easy capability for server-side control, but it can be used to prevent cheating, and most gamers do not like to tolerate cheats.

To get around all of this you need to learn more than just languages: you need domain specific knowledge for things like graphics, AI, math, physics, UI, scripting languages, networking, audio, game specific, optimization, software design, and so on.

If you want to use python as a start then by all means do so. Just understand that if you want to go deep into the rabbit hole, you will at some point have to learn the kind of stuff I have mentioned above.
 
  • #6
chiro said:
To get around all of this you need to learn more than just languages: you need domain specific knowledge for things like graphics, AI, math, physics, UI, scripting languages, networking, audio, game specific, optimization, software design, and so on.

If you want to use python as a start then by all means do so. Just understand that if you want to go deep into the rabbit hole, you will at some point have to learn the kind of stuff I have mentioned above.


Thanks, that was very informative.

I have quite a bit of time on my hands right now and I can self-teach myself pretty well.
Would you able to recommend some introductory resources for things you've mentioned?

I'm thinking about picking up some sort of 3D animation software. What's popular on the market right now?
 
  • #7
zeion said:
Thanks, that was very informative.

I have quite a bit of time on my hands right now and I can self-teach myself pretty well.
Would you able to recommend some introductory resources for things you've mentioned?

I'm thinking about picking up some sort of 3D animation software. What's popular on the market right now?

If you want an idea where things are going you need to understand what is current and the history of the specific domain.

Take for example 3D rendering. Triangle rendering is a very efficient technique and processes vertices is also a very efficient technique. Since a triangle defines a plane, it is then going to be common sense that rendering triangles is better than rendering higher polygons like quadrilaterals for example. Also you can do vertex operations and fragment operations in parallel, and this is important for rendering since GPU's have many vertex and fragment processors.

Now there are other methods of rendering such as ray-tracing, but that takes (at least at the moment) way too much processing power to render the kind of environments that games and animated movies render, even in render-farms with hundreds or thousands of computers.

If you want to learn the rendering pipeline, I suggest you get either OpenGL or DirectX SDK's and read the docs on architecture and the rendering pipeline, and you'll get a good idea of what is behind it all.

In terms of trends, I'm seeing that newer standards are supported patches. If you want to find out about these look at Bezier curves, B-Splines, and NURBS. I think personally this trend will continue where you supply parametric primitives that the GPU tessellates (i.e. makes into triangles) and renders.

Also things do change fast in this industry (like most areas involving IT). If you have deep understanding of the field however, you'll be able to keep up pretty easily.

Now there are a lot of resources out there, but I suggest that if you want to understand the stuff that is out there, look at math books, applied math books.

One book I think that will be helpful for you is the book "Real time rendering". It is comprehensive and lists a lot of topics that you can branch out and learn deeply. It's definitely one I would recommend.

You could pick up a "Game Programming using DirectX" book, but if you don't understand it, you'll be using it blindly and if someone goes wrong, you're screwed.

In terms of animation software, platforms like 3DSMAX and Maya are very comprehensive and very expensive. This is what professionals use. I should warn you, learning how to use these packages is a course in itself and is no short order.

There are some free alternatives out there however. One thing that comes to mind is the Blender program. I'm sure there are other ones out there though, just search for them.

If you have specific questions with regard to a specific domain, I will do my best to answer. It's just hard to give you a comprehensive answer to the above question because there are so many things to mention and one post is not nearly enough to even scratch the surface.
 
  • #8
I do know an open game where anyone can contribute with writing codes. The game is well played -there's always players 24h/24-. Google "spring project".
If I'm not wrong Spring is an engine that can support lots of games. The most popular is "Balanced Annihilation" (you might try that in youtube) though I know some other games are pretty popular too such as "Zero K".
There was a website that I can't find right now to show exactly the number of lines Zero K is written and in which program. Zero K was written in like (from my memory, around) 8 different programming languages and I do remember that Lua was widely used. All these games are in 3 D and really CPU eater. Even the best core i7 can't handle some of these games without lagging heavily in some situations, with all max graphics set on.
 
  • #9
fluidistic said:
I do know an open game where anyone can contribute with writing codes. The game is well played -there's always players 24h/24-. Google "spring project".
If I'm not wrong Spring is an engine that can support lots of games. The most popular is "Balanced Annihilation" (you might try that in youtube) though I know some other games are pretty popular too such as "Zero K".
There was a website that I can't find right now to show exactly the number of lines Zero K is written and in which program. Zero K was written in like (from my memory, around) 8 different programming languages and I do remember that Lua was widely used. All these games are in 3 D and really CPU eater. Even the best core i7 can't handle some of these games without lagging heavily in some situations, with all max graphics set on.

With things like that the routines that are resource intensive are usually compiled to libraries which are optimized.

Also when it comes to 3D rendering, pretty much at the end of it all, every program uses the same OpenGL/DirectX calls. So when you put up the settings like screen res, anti aliasing, texture resolution and so on, for the most part, it's just setting a few state variables, uploading higher res textures to the video card, or maybe setting a few state variables, and this kind of thing just puts burden on the graphics hardware and not so much on CPU cycles (there can be exceptions).

I think your suggestion about looking at platforms with multiple languages is good because typically most rapid game development environments use this kind of thing. 8 languages might be pushing it though.
 

1. What programming languages are commonly used for game development?

The most commonly used programming languages for game development are C++, C#, and Java. These languages are versatile and offer a wide range of tools and libraries that are specifically designed for game development. Other popular languages include Python, JavaScript, and Lua.

2. Do I need to know multiple programming languages to develop a game?

It depends on the type of game you want to develop. For 2D games, you may only need to know one programming language. However, for more complex games, it may be beneficial to know multiple languages to utilize their different strengths. For example, C++ for performance, C# for scripting, and Java for Android development.

3. Is it necessary to know a specific language for a certain game engine?

While it is not always necessary, it can be beneficial to know the recommended language for a specific game engine. For example, Unity primarily uses C# for scripting, while Unreal Engine primarily uses C++. Knowing the recommended language may make development easier and more efficient.

4. Are there any languages that are not suitable for game development?

There are no languages that are inherently unsuitable for game development. However, some languages may be more challenging or time-consuming to use for game development due to their limitations and lack of game development tools.

5. Should I focus on learning one language or multiple languages for game development?

It is recommended to focus on learning one language first and mastering it before moving on to learn other languages. This will allow you to become proficient in one language and understand the fundamentals of game development before delving into more complex concepts with other languages.

Similar threads

  • Programming and Computer Science
Replies
9
Views
1K
  • STEM Career Guidance
Replies
22
Views
3K
  • Programming and Computer Science
Replies
16
Views
2K
Replies
7
Views
2K
  • STEM Career Guidance
Replies
4
Views
2K
  • Programming and Computer Science
4
Replies
107
Views
5K
Replies
18
Views
2K
Replies
2
Views
792
  • Quantum Interpretations and Foundations
Replies
2
Views
645
  • Programming and Computer Science
Replies
6
Views
995
Back
Top