Choosing a 2D game engine for my project

Started by
17 comments, last by GamDev 11 years, 7 months ago
First, some background: I have average understanding of C++ and I've managed to code a few simple programs, however never made a game. Maybe I would've if my PC wouldn't have broken down, I didn't have enough money to replace it for a long time. by that said, I strongly prefer C++ over any other mean of coding, I find the language significantly more comfortable to use compared to anything else I've seen (Javascript, Java, Pascal to be precise).

I'm creating a new topic because I want up-to-date information.

Project description: my project is somewhat similar to Sonic, Dangerous Dave, Megaman, Mario graphics-wise. I can do without pixel-perfect collision, however I do ramps and "divided" tiles in the tilemap. The game is obviously 2D (NOT 2.5D!), there's gonna be shooting, interacting, weapons, etc..

What I'm looking for: I need the engine to come with object and event manager (call a sprite (bullet?), destroy a sprite on events, etc.), integrated physics, graphics and sound management, and the regular features, like time manager, text, input, animations, etc.. Preferably with at least some basic A.I. too, but not necessary. Some basic LUA integration may be useful too, but it's definitely unnecessary.

P.S. I'm not looking for 10 different engines that I'd have to tie into one myself (graphics, zip, sound, physics, etc.), I'm looking for one solid product that I could use. I'm also not looking for paid engines, I'm looking for a free engine that would allow me to release commercial products.

If you have any questions, feel free to ask.
Advertisement
I know this isn't really what you want but I thought you might find it worth it to write your own simple engine if its only simple 2d. A simple api like SDL will actually handle a ton like sound, Image loading, input processing, Sprites can be done via a BLIT and there are plenty of SDL extensions that do allot more. If you want physics roughly equivalent to sonic it wouldn't take much extra programming. I even have some code samples I wrote of a very basic platformer that I could send you if you'd like, they cover animation via spritesheets and some basic physics (in C++ of course).
If you want something like that, you will need to use an engine that costs some money. Don't be afraid to lay down a hundred dollars or so, it is well worth it. Bellow is a list that might interest you.

Torque2D
Allegro
Source Engine

I know this isn't really what you want but I thought you might find it worth it to write your own simple engine if its only simple 2d. A simple api like SDL will actually handle a ton like sound, Image loading, input processing, Sprites can be done via a BLIT and there are plenty of SDL extensions that do allot more. If you want physics roughly equivalent to sonic it wouldn't take much extra programming. I even have some code samples I wrote of a very basic platformer that I could send you if you'd like, they cover animation via spritesheets and some basic physics (in C++ of course).


I find the entity (bullets, etc.) system rather difficult, and pixel-perfect collision (which I assume I'd have to use for ramps) immensely difficult. I remember struggling a lot with them. A lot!

Anyway, I also remember shaking SDL, as I remember that it wasn't updated for a long time, and is half C, half C++.

I would appreciate if you'd send me the source code of your platformer though, I guess we should take this to PMs?


If you want something like that, you will need to use an engine that costs some money. Don't be afraid to lay down a hundred dollars or so, it is well worth it. Bellow is a list that might interest you.

Torque2D
Allegro
Source Engine


Be afraid? I'm not afraid, I don't have the money! I couldn't even afford to fix my PC until recently!

Allegro's free and it offers only outdated C code as a graphics wrapper.

Source Engine is 3D.
Just so you know, Source engine has been used many times in the past to make 2d/2.5d games.

I know many of the people who write patches to allegro on an ongoing basis, Allegro and C are anything but outdated.
Allegro is actually a highlevel SDL wrapper, and there is a c++ wrapper written for it.

Don't cringe at wrapping C code into a c++ game. Often this is the fastest way to get things done.

Just so you know, Source engine has been used many times in the past to make 2d/2.5d games.

I know many of the people who write patches to allegro on an ongoing basis, Allegro and C are anything but outdated.
Allegro is actually a highlevel SDL wrapper, and there is a c++ wrapper written for it.

Don't cringe at wrapping C code into a c++ game. Often this is the fastest way to get things done.


As I've stated in the OP, I'm not looking for a 2.5D engine. As for using a 3D engine for a 2D game, it is counter-productive and overly-complicated, often it's also a overkill for the end product as well.

Interesting, I'll have to take a look at Allegro and SDL. However, I am against C code, when there's C++, up-to-date is my preference, and often is more productive and has better performance. I can't comment ont his particular situation though, as I don't have enough knowledge about it. But anyway, as far as I know (now), SDL offers various plugins, maybe even those that I need - entities, physics, sprites, tilemaps, etc., while Allegro doesn't, in which case, SDL has a huge upside over Allegro for me.

Allegro's free and it offers only outdated C code as a graphics wrapper.
[/quote]

Don't ever forget that C is C++. Any C is perfectly valid C++, and C isn't really outdated Its still used for a lot of modern programming.
These are html5-Javascript based 2d engines with full cross-platform support. Worth checking these out:

http://impactjs.com/

http://craftyjs.com/

http://www.melonjs.org/
since you are considering Allegro and SDL, I would advise you to have a look at SFML as well. It is entirely C++ based and is a modern object oriented alternative to SDL or Allegro. I have found it very intuitive and easy to get into. check it out at http://sfml-dev.org .
I had this same problem ( not knowing what 2D engine to use ) and I ended up writing my own.
My main issue with most 2D engines is that they don't support shaders.
Even Torque 2D has just some silly blend modes that makes me think that they just use fixed pipeline when rendering everything in there.
Using a 3D Engine for 2D games might give you a lot of work too. You will need to change the way physics works if you wnat to make a sprite based engine ( not just a 3D game where you see the character from the side). This can be easy or not depending on what you choose here. For example for UDK it's nearly impossible to change the physics code and replace it with Box2D since you don't have access to the sources.

In the end you need to ask youself what is the end goal.
Do you want to make a game in order to sell it? I doubt it can be successfull given the huge amount of first-project flops that come even from experinced programmers.
Not wanting to discurage you here, but since you mentioned PASCAL I start to believe that you're not that experienced with game development or programming in general.
If you want to make it for your portofolio, you could impress people more if you do your own engine. It would also be a really nice learning experience.

This topic is closed to new replies.

Advertisement