• Advertisement
Sign in to follow this  

Component-driven games

This topic is 3630 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

OK, so I’ve been googling this topic for a while, and I admit it sounds very attractive. The question is, how do you actually make it?? Most of what I found are theories but no example codes. This is what I understand about CDPs so far: The entity/object that holds the components is just an ‘ID’. No other data is required. Components only have data, no functions. So for example, graphical components have the data necessary to draw it texture or mesh, but doesn’t actually draw it self. Components contains the Entity’s/Object’s ‘ID’ to know to what it belongs too. It all sounds great and all but, how is this actually structured. And if the components don’t have the functions to update or draw them selves, then what does?? Thanks.

Share this post


Link to post
Share on other sites
Advertisement
There was a thread about component based systems, you can find it here. It turned out to be quite a large thread with a good amount of code. It's certainly a good read.

Share this post


Link to post
Share on other sites
Man, that post was 5 pages long x_x I only finished 3 pages.

I got a good picture on how to make it. But these are discovering more problems than solutions. :P Great ideas though.

I can start testing it in code to figure the rest my self. Thanks for the link.

Cheers

Share this post


Link to post
Share on other sites
Above all, the most important thing to remember is to use the KISS rule. Do what makes sense to you, not necessarily what other people think is the best solution. Component-based design is just a guideline, not a hard formula. More than not the simplest design is the best one.

[Edited by - fd9_ on March 16, 2008 1:35:03 PM]

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement