refactor baccarat