Me ranting for 8 Min straight about Game Engine Dev and Serialization

https://www.youtube.com/watc...
● My Discord Channel: http://bit.ly/discord-uniday-us That's just the tip of the iceberg. The point that I was explaining in the video is that, for everything in the engine, I currently need to do 4 things (and later, 5): (1) serialize it to save to disk, (2) deserialize it from disk and properly initialize the stuff in memory, (3) display that in the editor's UI, (4) reflect it for Python API that I don't even get to show in the video but trust me it's bad, (5) in the future, reflect it as well to the visual scripting API. The code for all that it's very simple, most of it basically only needs the field offset, size, type and address and some "simple" handling code... but I still fails really, really, really hard to simplify this so I don't need to write the same thing five times in a row. And as I said, that's just the tip of the iceberg, because the other major issue is that every time I change how the classes looks like, it will inevitably change how they are serialized, meaning that the previously serialized bytes won't make any sense anymore, making it impossible to open your projects without getting everything corrupted (yes I had a flag to avoid corrupting stuff, but it just means that the engine will not load the asset at all). The best world would me something like a json file, that can handle changes (like reordering, additions and deletions) just fine. But guess what? If I can't even do the part one, which is remove the need to write the same stuff 5 times, adding json will just add even more redundant code. And as I showed in the video, cave engine is not a simple project anymore, it's a ~130.000 Lines of Code giant already. So it's not trivial to rewrite it. Sorry for the vent, but this thing have been keeping me awake at night for at least several years already. If you feel the pain, consider buying me a Coffee (Patreon) or at least donating some money for the migraine medicines that I take while trying to figure this stuff out: http://bit.ly/patreon-uniday ························································ ► Uniday Studio By: Guilherme Teres Nunes
Home
/
Indie Game Developers
/
Guilherme Teres
/
Me ranting for 8 Min straight about Game Engine Dev and Serialization