diff --git a/src/main/c/Stefan/slot_machine.c b/src/main/c/Stefan/slot_machine.c index a779776..114583d 100644 --- a/src/main/c/Stefan/slot_machine.c +++ b/src/main/c/Stefan/slot_machine.c @@ -15,8 +15,6 @@ void slotMachine(){ int bet = getBet(balance); balance = subtractBetFromBalance(bet, balance); - printf("Guthaben: %d\n", balance); - randomizeSymbols(symbols); spin(symbols, bet, balance); @@ -89,8 +87,10 @@ void randomizeSymbols(char symbols[]){ int spin(char symbols[], int bet, int balance){ showResult(symbols); - int winnings = getWinnings(symbols, bet); + int winnings = getWinnings(symbols, bet); + balance += winnings; + printf("Aktuelles Guthaben: %d\n-------------------------\n", balance); return balance; }