Graphics

Pages: 12
I don't mean to spoil the party here, but do the folks think Chillieman's indeed ready for 2D graphics and 3D games? Has he fully got into OO programming yet (which I imagine essential?)?

Don't mean to poke at all - I'm reading the same book and plan to go down this path. I'm just interested in what the other coders consider "good enough" to get into APIs and whatnot for game programming so I know when the time comes myself.

Good luck either way Chilly :)
Last edited on
closed account (Dy7SLyTq)
basic 2d gaming isnt that difficult. and learning oo isnt essential. sdl is written in terms of c and sfml has a c version. for 2d he doesnt have to get into opengl, just sprite manipulation
Agreed. As I previously mentioned, I'm of the opinion that you should learn to do what you want to do. If you want to make 2D games, then that's where you should start.

Language and general programming concepts can be learned along the way. But if you're doing something fun while learning them, it'll make learning them easier and they'll stick with you.

EDIT:

Also, while SFML has a C version, I recommend you use the C++ version because it's generally easier. C++ means RAII which means automatic cleanup which means it's harder to screw up.

Using existing OO code is easy. Writing OO code is what can be tricky.
Last edited on
closed account (Dy7SLyTq)
i agree that you should use the c++ version, i was just pointing out that knowing c++ isnt neccesary, although i would learn it
What kind of level of 2D are we talking though? Does your answer apply to games like World of Goo, Badlands etc with multiple layered backgrounds and physics implementation? I for one can't wait to get into those kind of 2D games, but I'm not sure when exactly the right time is (still learning C++ of course)?

Is implementing something like 2DBox with SDL where the toughness starts? I've always wondered this. Surely it's easier just grabbing an engine like Torque2D and editing it to my needs? I never see that though, developers of standout 2D games tend to make their own using things like 2DBox and SDL.
Box2D*
It is ALSO where it starts from.
But hard topics are also custom file formats like levels, textures and models (if there will be any, in a 2d game), and sound, unless you keep it in a friendly format.
Then if you want a precisely-colliding game, you need collision models too (You don't need it for a pokemon-like game, those kind of games are square-collision-based and you are probably going better doing calculations by yourself) which defines how objects will collide.

Also, you need to make a level editor and texture/model converter.

Then you need to link the most important things up, mainly:
Graphics
Physics
Audio
Input
Logics (Scripting)

Personally, I use Box2D, and after the first troubles I'm doing good with it.
For 3D, Bullet, but I see some commercial games (Like Amnesia and Penumbra) use Newton.

For scripting, I used to use Chaiscript (but it's quite slow) and I see (again) commercial games (Like Amnesia and Penumbra, yes, they're very similar) use AngelScript.

I would recommend you to keep the most used file formats and to "zip them up" in a packed file with your own format, so they will still be hidden and unedited from externals, unless you want to support the modding community giving away your tools.

If you're going for networking, I suggest you, DO NOT DO IT.
Not right now, at least.
Make sure you learnt everything in the proper way before going to do such a complex thing.

But if you're crazy, go for RakNet, which is free for non-commercial purposes.
Or you could also go on your own, but UDP connections are troubly and TCP connections are slow.

Then last step could be optimization and caching, but do it very carefully.

Also make sure you do have a very good debugger.
I like the idea of learning a language at the same time of making what you want, but that sounds very hard to do while learning C++.

Is there a benefit to doing it your way over using Torque2D (which has 2DBox, graphics, sound, script etc). Torque2D's engine is completely open-source / commercial free too. Works on Mac, PC, iOS (though sadly not Android).

Ofcourse aside from gaining experience and something to be proud of, I can't seem to see the reason for making one from the ground up over grabbing an engine that's so very similar to the tasks you want already, that way you can jump straight in. Ofcourse I have a lot to learn, but what do you think?
Last edited on
I don't have any experience with Torque2D.
But what I can tell with my experience, keep looking for libraries until you find the one which suits your needs.

TL;DR: Try it.
Chillieman: I have found a way to use Allegro with OpenGL to create 3D images, I have not done any animation yet, I have not had the time to try it, but I was able to create a 3D object on the screen. The only part of OpenGL you need to download is the GLut, and you do need to download Allegro also.

if you would like to get started with Allegro, here is two different tutorials by the same guy:
Non-Object Oriented:
http://fixbyproximity.com/2d-game-development-course/
and an Object Oriented Approach of the same game:
http://fixbyproximity.com/oop-game-development/

and to get started with Allegro with OpenGL
http://cplussplussatplay.blogspot.com/2011/12/open-gl-allegro-51-basics-textures.html

this one doesn't show how to set it up, but it's fairly easy, I just followed the tutorial that you posted to set up the GLut, but nothing else and then if you put it in addtional includes and additional libs in your IDE, these projects should run fine. let me know if you have any problems
@Chillieman
GraphicsGale is a pretty good editor for 2d/pixel art. You can easily add sprite frames and have them animate while you edit.
Last edited on
Topic archived. No new replies allowed.
Pages: 12