In divorce cases, typically someone is going to move and the Court understands this; however, there may be some negative ramifications of moving out of the martial residence. There may also be some financial responsibilities to which you may or may not be obligated to pay. Each case is different, as such, it is best to talk to an attorney prior to moving.
The short answer is, if you have an interest in the marital residence, you will not lose the interest by moving out.