Page 1 of 1

What features should be in a 2D Engine?

Posted: Sat Oct 13, 2007 3:29 am
by Rook Zimbabwe
I have been trying to organize my thinking on this... What features should be a part of a 2D engine?

I figure:
1. A map reader scheme
2. Emitters
3. Pathfinding
4. Gravity
5. Collisions

what have I forgotten? :D

Posted: Sat Oct 13, 2007 5:09 am
by Fluid Byte
Mode 7, like MarioKart!

Posted: Sat Oct 13, 2007 9:24 am
by Derek
Most important, even before fancy graphics and emitters, GAMEPLAY.

There are a lot of simple games out there that play so much better than the multi million pound/dollar great looking games from the major studio's.

Edit. Just realised that you are asking about an engine, not a game. :oops:

If you could write an engine that injects gameplay then that would be fantastic. :lol:



I think you'll need a sound system that can be triggered by events.

Posted: Sat Oct 13, 2007 2:27 pm
by DoubleDutch
Things I used to use:

Sprite palettes <- reuse the same baddie sprite -but different colours
Sprite HV flip <- saves drawing/loading
Layers (parallax scrolling) <- Gives illusion of depth, looks good (aka Sonic / shadow of the beast, etc)
Animated maps <- Water effects, doors, etc
Brain callbacks <- make baddies "clever"
Joypad emulation for brains <- so you can "take over" a brain to test things out
Map based sprites <- to create huge multiscreen baddies (in Mercs I had a baddie 7 screens tall!)

Sprite palettes and HV flip are much needed in PB - I don't know if this ability is available in direct x or not though? Basically with sprite palettes you can draw a sprite that wold be mapped to a palette (like a 256 colour screen is mapped to a palette). You select the palette when you draw the sprite and it's colours are remapped on the fly. Yu can have multiple palettes and select them at will when drawing. HV flipping is much the same - it's done at drawing time to save video memory.

Posted: Sat Oct 13, 2007 10:43 pm
by Rook Zimbabwe
If you could write an engine that injects gameplay then that would be fantastic. :D
That may be a bit oput of my league!

As far as all the sprite functions... I have been reading the DX9 whitepapers lately... This I will start simple, map reader first. Using tiles made with World Creator Freeware!

Posted: Sun Oct 14, 2007 2:44 am
by dracflamloc
are you talking about a 2d game engine or a 2d rendering engine? big difference in requirements there.

Posted: Sun Oct 14, 2007 4:11 pm
by Rook Zimbabwe
2D Game engine... Like Haaf's Game Engine, but workable in PB.

Posted: Sun Oct 14, 2007 6:16 pm
by BasicGuy
Hey Rook, I've had a long time interest in producing a 2D Isometric engine. Isometric is still a game genre that has some worthwhile activity is seems.

Something I've considered, in addition to what has been said is the ability to read Mappy files. Why build an editor when a very good one is already available?

OpenGL ES... Already very workable on mobile devices and that my friend, is a very real future for games. Coupled with simple navigation interface, 2D/ISO games could have a real market IMO.

Cheers!

Posted: Sun Oct 14, 2007 10:59 pm
by Rook Zimbabwe
But unless I have heard wrong (and I may have) OpenGL ES is a Java based subset... What we really need is something in PB for PB (or all langs!) I really liked HGE (Haaf's Graphics Engine) but it is wonky in PB as far as I have worked it out.

Sadly I figure the failure with HGE is due to me. I cannot fathom how to write the interface. I did ask for some resources, but that was not asnwered. There may be no tutorials on how to write a communicator for a DLL... :)

Posted: Mon Oct 15, 2007 12:28 am
by BasicGuy
But unless I have heard wrong (and I may have) OpenGL ES is a Java based subset...
Nah, it's just that the Java guys jumped on it first because of the availability of a JVM for mobiles. The actual JVM name escapes me at the moment, but I was messing about with it about a year ago. OpenGL ES is linkable to a number of languages and I can't see any outstanding issues in using it with a PB wrapper...

Java is cool, but using it is like "shooting a fly with a bazooka"... Way too much typing for one thing...

I've looked at HGE a bit and came to the same conclusion... Writing to the interface is not an easy task...

I DO think however, that a well-thought out PB based 2D game engine would be cool...

Posted: Mon Oct 15, 2007 4:03 am
by Rook Zimbabwe
You see one of the problems I have is that the emitters in PB require you to start the 3D engine... What if the user does not have a 3D card... If you are writing a 2D game (even an isometric one (a format I too love!)) you don't really need to turn on a 3D engine...

I suspect that possibly 60% of the people in this world with a computer have NO 3D capability.

Then again statistics show that over 78.1% of all statistics are made up on the spot! :D

Still I am gonna start with a map reader and a informal particle system. Font sytem added later.

Any ideas and help on the map reader/map engine would be appreciated.

Posted: Mon Oct 15, 2007 5:15 am
by Rook Zimbabwe
I have thought of just diving in to this:

http://www.mapeditor.de.vu

The code does not work on my 4+ version of PB though... it has problems in type declarations (I have ALWAYS had problems with type!!) :oops: