Alot of refactoring, less RAM usage and faster