I managed to get past the third badge before encountering a major bug.
It was in the secret base, training with the level trainer, using Togekiss against level 50 Audino.
I used Metronome constantly, eventually triggering Thousand Waves. That one crashed the game.
There are other minor bugs as well, though this is the only one that really bothered me. It says in the wiki that it's fixed, but it appears not.