introduced q js and some defers and promises. Also prepared some things for loading levels