I touched on Component Based or Entity Based Game Architecture very briefly in my FOTB talk. This video covers a bit more, but same basic principles. It then goes into some of the specifics of the Push Button Engine, but even if you don’t go with that engine, it’s a pretty good intro to the concept.
Wow. I was brainstorming problems with OOP and making physics engine and flexible enough UI library in the beginning of this summer and came to very alike structure because of the same problems he mentioned. I heard of PBE but this probably is final and biggest drop to go and check it out. I wonder if I will find answers to few problems I have not solved yet in such project decomposition.
Interesting video Keith, I was in your session at FOTB and have been developing a simple Asteroids game and ran into similar problems. I had two classes that extended from enemy, one that follows and one that shoots, but I wanted one that both shot and followed. So the idea of a component-based game architecture really makes sense. It’ll be good to see your code examples of how this could be implemented without requiring development overheads, such as creating public methods on the entity to access the component’s methods. Admittedly, I haven’t checked out the PBE source, so that could answer the questions I have surrounding component-based architecture.
Mark (@mark_star)
Hi! what do you think about pushbutton engine?
I remember reading something like this in one of the game programming gems books. Nice video!!
I’m quickly becoming keen on component based architecture, I always knew there was something iffy about oversized parent classes.. This might be of interest: http://cowboyprogramming.com/2007/01/05/evolve-your-heirachy/
Looks great
Having problems organising my OOP at the moment, although I think I just need more practice.
[...] from scratch myself. I’m looking forward to seeing what Keith comes out with. Keith has also posted a video (from PushButton Engine) about using composition over inheritance for games; it’s definitely [...]
Interesting… I’ll have to take a look at that.
Speaking of components… you should update minimalDesigner.
[...] Probably the most known, best documented and most active game engine for ActionScript. The PushButton Engine is build around the concept of “components”, which, to me, feels very natural, especially for a game. Watch this short introduction to get the gist of it (via BIT-101) [...]
I have just released my opensource project which combines entity architecture and DI. This is more a framework than a full game engine
http://wiki.github.com/tdavies/Ember/