Safe saving point. ReDid some of the code to make it as clean as possible.