My first thought was also "Destroyer Command", but this is quite old now and I imagined someone else would come up with a more recent iteration, if there is one.
Here's a link to the Wiki description anyway. As you'll see, there was a degree of online sub-surface ship interaction possible with "owners of SH2", so you could find yourself dodging torpedoes, provided you could find some subsimmers to play with. I've had this in my collection for a long time, but with so many other games still waiting for a test-drive, I never got around to playing it; the graphics are of their time... contemporary with SH2, that is.
I don't know whether you get attacked by subs while you're in command of surface vessels in the "Battlestations" games; I'm surprised someone hasn't mentioned these already.
__________________
|