player names fix new line
This commit is contained in:
parent
52978dd616
commit
37a0a4f74a
6
main.py
6
main.py
@ -51,11 +51,11 @@ def change_player(): # Prüfung welcher Spieler dran ist. (Funktion Spielerwech
|
|||||||
if run:
|
if run:
|
||||||
if player == '\x1b[1;34m' "X" '\x1b[1;0m':
|
if player == '\x1b[1;34m' "X" '\x1b[1;0m':
|
||||||
player = '\x1b[1;31m' "0" '\x1b[1;0m'
|
player = '\x1b[1;31m' "0" '\x1b[1;0m'
|
||||||
print("Spieler " + name_player2 + " ist dran.\n")
|
print("Spieler " + name_player2 + " ist dran.")
|
||||||
|
|
||||||
else:
|
else:
|
||||||
player = '\x1b[1;34m' "X" '\x1b[1;0m'
|
player = '\x1b[1;34m' "X" '\x1b[1;0m'
|
||||||
print("Spieler " + name_player1 + " ist dran.\n")
|
print("Spieler " + name_player1 + " ist dran.")
|
||||||
|
|
||||||
|
|
||||||
def name_players():
|
def name_players():
|
||||||
@ -65,7 +65,7 @@ def name_players():
|
|||||||
|
|
||||||
|
|
||||||
if name_players():
|
if name_players():
|
||||||
print("Spieler " + name_player1 + " ist dran.\n")
|
print("Spieler " + name_player1 + " ist dran.")
|
||||||
|
|
||||||
|
|
||||||
def check_win(): # Prüfung ob 3 Felder mit X oder O hintereinander (Horizontal, Waagerecht, Diagonal) belegt sind.
|
def check_win(): # Prüfung ob 3 Felder mit X oder O hintereinander (Horizontal, Waagerecht, Diagonal) belegt sind.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user