Major refactoring

Split classes into different files, reworked events system to be more
modular and with clearer areas of responsibility.
Refactored renderer init