So I Finally Took Time to Make a Game (Sebt3)


@pmprog you are completely correct that C++ programs can't necessarily compile as C, but I think you have missed the point being made (or put better, I have failed to make my point obvious). You can take C code and compile it as C++, it is then C++ code, and you can't argue there is anything wrong with C++ at this point (after all it is just C code!). So you can write a full game, compiled as C++, yes it could also compile in C, so up to this point there is still no problem with C++. Later in my post I then talk about some of the things that can cause problems with C++, I think we all agree there that it is easy to write C++ code that offends people and certainly won't compile under a C compiler.

It is also worth mentioning that for a while the major C++ 'compilers' actually just converted the C++ code to C code, and then called the C compiler, the major compilers no longer do this, but it gives some idea of the closeness between the languages, especially earlier on.
 
Wow, it started a real debate.

What I personally meant by saying "going the C way" wasn't really about language features but more about the programming paradigm (procedural vs object-oriented) and the facilities offered by the language's ecosystem.

As Sebt3 was saying, making the game engine is primarily a learning experience. So, sometimes, I'm thinking about how it would have looked had I done it in just plain C without objects. Articles such as this one got me thinking about it. And Sebt3's choice to go the same way piqued my curiosity.
 
Something that has received some amount of popularity/interest in the last few years is 'component based' architecture, I won't explain it in detail as there are better sources on the internet, but essentially everyone entity in your game is made up of a series of components, it moves away from inheritance and back to the (originally recommended composition). It is still quite a new area (to most), and as such there isn't so much readily available information on how to implement and solve all the various issues, but it is at least rather interesting.
Isn't this similar to what Microsoft pushed for with his COM model in the 90s?
 
Back
Top