First total refactoring

TODO: Engine.cpp!!!