fix money count in case of bust or blackjack, and refactor