Project Raygine #4

Reworking the serialization system is making progress. Still not sure if this'll stay this way, but I like the direction it's going.

One fundamental design change is, that an asset object is now a collection of types. A type is a declaration of attributes that can be serialized and an asset contains any number of instances - which I call objects (yeah, not very creative). When deserializing the asset, the attributes in the type restore the values of the objects and additionally, a metatable can be assigned to the object. No more constructors or factories or so - just a metatable that is assigned to the table of the data.

Having a list of objects in an asset implicates a few things:

I still have a lot of work left to do on the subject - especially removing all the old stuff that is now obsolete. But I'm confident that this will be a good foundation for the future.

The way things get rendered in the inspector is also changing; There's now a type_gui registry where GUI logic can be registered for types. I want something similarly flexible as the property drawers in Unity, where the GUI can be customized for specific types inside specific types. With this, I am changing away from ImGui's default "label to the right" approach and am displaying the labels to the left, which I think is more readable and more "standard".

Here's how the project_settings are looking like now:

Project settings

đŸĒ