Monday, June 11, 2007

Don't worry

Don't worry I havn't fallen asleep on this project. But I have been finding it slightly harder to get motivated on it. I'm cooking up lots of crazy things on every side of the scale and it has caused major revisions to the code. Oh hell I'm already typin I might as well tell you about them...

First off I added another layer of abstraction above the cModel class, now all instances of a model in the scene are referenced through a cModelInstance class. This allowed me to stop duplicateing certain data per instance such as the physical parameters and render settings. Basically the only unique thing to an instance is its location and some material properties for things like reflections.

With the new level of abstraction I know have an XML file for each type of model that contains parameters such as it's physical shape and level of detail information. Each model only gets loaded into the engine once and each subsiquent addModel call simply instantiates a cModelInstance, spawns new physical entitys, and occasionaly graphical entitys.

With all that having been said, I can now modify the parameters of any instance of a model and it will apply to all like models in the scene. Also the scene XML files no longer need to include duplicate information for each instance of a model.

The debug GUI is looking great, it is beautiful. The reason I call it the debug GUI is it is strictly for scene creation and modication. It will also be used to modify the "In-Game" GUI which will be customizeable by the user.

More to come soon, my friend is here :)

No comments: