Quote:Original post by Emmanuel Deloget
Question: how do you manage
1) data duplication (the bounding box can be of interest to various components; should all components have an embedded bounding box)?
Well, if some data is potentially used by multiple subsystems I'd create a corresponding component.
Quote:Original post by Emmanuel Deloget
Question: how do you manage
2) components requirements (because I have this component, I shall also have this other one)?
I'm not sure if I fully understand that question but if multiple components are needed the subsystem would check for those components individually and either reject the entity or create a default component (a bounding box, for example, could be calculated from other spatial data).
Other components could be optional. As an example the visual subsystem could expect the mesh but could also make use of some shader component.
Edit: I'd not use the Observer mechanism to change the order of processing but to build lists of entities that have changed. Then when it's the subsystem's turn within the processing order it will remember what entities/components have changed and only process those.
[Edited by - Lord_Evil on October 30, 2007 2:14:08 PM]