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.
Resources
Search
Archives
Categories
Meta
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.
Interesting… I’ll have to take a look at that.
Speaking of components… you should update minimalDesigner.
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/
One of the key tenants of OPP is to “favor composition over inheritance”. Component-based frameworks take that principle and make it far more concrete.
here’s my experiment with this type of architecture:
http://programyourfaceoff.blogspot.com/2011/04/lets-build-game-engine-0-introduction.html
I have since retired my efforts on this project.
The souce code is still available here if anyone is interested but the above link is broken.
Thanks for the article, I recently wrote something similar and had a scope of what people are doing with this type of development.
Not so much code but mainly ideas:
http://boxhacker.com/blog/2012/02/22/game-components-infrastructure-for-xna/