A town justice in Ulster County agreed to resign on Friday amid a six-tiered state probe that included allegations she was adversarial to police in Saugerties, and ill-mannered to court staff and spectators.