Today I created the Tic Tac Toe game. I finished creating it. Next Friday I will develop the game and make it better
# check diagonals conditions
if game_btns[0][0]['text'] == game_btns[1][1]['text'] == game_btns[2][2]['text'] != "":
game_btns[0][0].config(bg="cyan")
game_btns[1][1].config(bg="cyan")
game_btns[2][2].config(bg="cyan")
return True
elif game_btns[0][2]['text'] == game_btns[1][1]['text'] == game_btns[2][0]['text'] != "":
game_btns[0][2].config(bg="cyan")
game_btns[1][1].config(bg="cyan")
game_btns[2][0].config(bg="cyan")
return True
Leave a Reply