Camera refactoring in the engine