Rail users stranded as police hunt gunman