If memory serves, Trainz gets the handle of the default audio output device. If you change it, you need to restart the program.