There isn't really an impending collision. The 2 galaxies will merge, change shape, trade mass back and forth and possibly then form one larger galaxy. But objects in those galaxies will not actually be impacting each other. There are billions of miles of space between the objects in each galaxy making collisions between stars and planets highly unlikely.