Tic Tac Toe Using Python and Pygame (Part 4) | Winning and Restart Function

preview_player
Показать описание
In this tutorial I will show how to code Google's Tic Tac Toe using Python and it's Pygame module. In this video we will be checking and drawing a player's win, and we will be coding a restart function in order to play again when is game over.

LINKS:

FOLLOW FOR MORE:

⏱ TIMESTAMPS ⏱
00:00 Introduction
1:08 Declaring Remaining Functions
2:56 Check Win Explanation
4:57 Vertical Win Check
6:28 Horizontal Win Check
7:23 Asc Diagonal Win Check
8:10 Desc Diagonal Win Check
9:00 Vertical Winning Line
10:57 Horizontal Winning Line
12:10 Asc Diagonal Winning Line
12:49 Desc Diagonal Winning Line
13:23 Check & Draw Win Test
14:45 Gameover Variable
16:31 Restart Function
18:15 Final Game Test
Рекомендации по теме
Комментарии
Автор

Make sure to check the AI version tutorial :)

codingspot
Автор

one of the most beginner friendly and well thought out tutorials out there! great work and thanks a lot!

Bcitality
Автор

Clear Explanation, Clear Code, Huge Respect I wish I found this video first. You earned a subscriber and thanks man.

chaoticsadist
Автор

Hey you have to add “game_over = False“ in the restart Function, otherwise you won‘t be able to mark any square after a win.

oskar
Автор

An awesome video series. We are waiting for new and more complex video series.

fatihkomurcuoglu
Автор

Great video. I learnt how to design my first game on Python using this tutorial

saadabdullah
Автор

Loving the work that you are doing man! Keep it up!

Siddhesh
Автор

This was a very good tutorial series! Thank you, I learned a lot!

BinkingThig
Автор

I appreciate your work, please keep on doing nice stuff! :)

erikheie_ich
Автор

very good videos and great explanations. Helped me a lot!

georgikoynov
Автор

Thanks for the tutorial You are awesome :)

alfonzo
Автор

Love this tutorial but im confused. Why do you use square brackets instead of normal ones in some cases. I'm still a bit new to python.

jaynaii
Автор

Nice videos man. Really helpful for learning pygame. Keep up the good work! Do you have a developer background?

baconloverjeff
Автор

Hello, I really appreciate your work. I was just wondering on how to get the restart function working when you win.

GPRox-opjm
Автор

I restarted my screen it draw all lines now when i tried to draw circle or cross after restart it don't draw a single line don't know why kindly help me with that

pushpendradas
Автор

Hello, When I run the part of the game over variable the o's don't show up only the x's. If you can can you help me out?

premixedllama
Автор

Hey so my posx and posy arent working, any fixes?

derpiepro
Автор

Hey can you help me or guide me on how to create the START enter page for this tic tac toe game cuz I need this for a school project but I don't know where to start. I'd appreaciate it a lot. Please

lauretahoti
Автор

why do the winning lines omly work vertically

lauretahoti
Автор

sorry but one question. When a player wins by two ways, say horizontal and vertical at the same time, it'll only draw one of the lines so how do i go about fixing that

mancityp