refactoring the level generator and working adding support for #5