Fixed bug with random level generator