what happens when gas in a nebula's center stops collapsing?