Implemented the prototype scene manager. It's ugly. Further changes are now pending.