Lots of work and refactoring
Import resources automatically