This is a cool battle. Gray uses his slower Pokémon's brute strength, and often uses his opponent's momentum against them. Basically what he did was, when Riolu charged forward and barreled into him for the Quick Attack, he made Nidoran turn around at the last second and shoot his legs out for Riolu's face, so that the Fighting Type's momentum would force him to crash into Nidoran's hooves.