Structurize code and separate overlay into multiple overlays