What if a spouse has misbehaved during the marriage, by gambling excessively, using drugs illegally, having an affair, or similar behaviors?

Bad behavior does not usually affect how property and debts are divided.  An exception to this general rule is when the misbehavior was intended to and resulted in the destruction of property or waste of community assets, by wasting money gambling excessively without the permission of the other spouse, for example, or lavishing gifts upon an extramarital lover without the spouse’s permission.  Behaviors such as domestic violence, intoxication, emotional abuse can seriously affect a parenting plan, however.