More than 30 people have been injured, one severely, after two rollercoaster trains crashed into each other at an amusement park in southern Germany.