Last changes (unpublished):
- Smooth lighting is back, and improved !
- Map format has changed again, it becomes a “2d” map format
- Changed lots of things in the engine
- Less memory usage, better performance
I introduced a new map format, it now becomes sort of 2d format (somehow like Doom or Duke Nukem), I don’t store anymore all the cube information, but just a top view file. For every 2d coordinates I store information about the texture and the maximum height. It means there can’t be solid platforms in the air anymore, and I will have to use sprites to make platform (as we could see in Duke Nukem for example, Duke Nukem was also using silent teleporters to simulate multiple layers in a building, sadly it wouldn’t work nicely in current view I think). This format will only be used on Android I think, the level editor and PC version will still use 3d map storage.
I’ve completely removed compatibility with old map format (the one currently used in PC version) as it saves memory and makes code easier to read.
There has also been huge changes in the game engine lately, rewrote lots of collision detection, sprite memory storage,…. Some things are now considered 2d, as a result : less memory usage, and less CPU usage.
The smooth lighting is back, as maps are pre-rendered, it doesn’t impact performance at all, except when maps need to be re-calculated real time, but it doesn’t happen that much (when opening doors, or breaking walls).
And finally, thanks to all optimizations above, I consider the game playable on my phone, it’s good news (sometimes fps drop from 30 to 25, but it’s ok).
I will now review all the maps, correcting small issues, adjusting lights,… and eventually, if everything’s fine, I should be able to publish a version… on Google Play
It’s kinda crazy how things changed for this game, the first game version was very very different than current one. As it is my first “true game” it’s understandable, but at some point I wonder if I shouldn’t rewrite the whole engine, instead of deep refactoring once in a while…