Sub4Sub network gives free YouTube subscribers
Get Free YouTube Subscribers, Views and Likes

How to Make Chess in Python!

Follow
LeMaster Tech

I made a followup to this video adding En passant, castling and pawn promotion available here:    • Adding Castling, Pawn Promotion and E...  

This is a complete tutorial for a twoplayer python chess game using the PyGame module. This allows two players to complete in the classic game of chess complete with checking valid moves for all pieces on the board, putting kings in check, and tracking defeated pieces as well as forfeiting and restarting!

ALL CODE AND ASSETS HERE:
https://github.com/plemaster01/pygame...

Massive thank you to Patreon Supporters Dale and Philip!!
Please consider becoming a super supporter of the channel here:
  / lemastertech  

Consider checking out my personal channel for fun Engineering builds:
   / @peterlemaster8310  

TIMESTAMPS:
00:00:00 Introduction and Python Chess Showcase
00:03:30 Basic Pygame Setup
00:08:27 Importing Chess Piece Images and Setting up Lists
00:22:56 Drawing the Board
00:34:03 Drawing Chess Pieces Onto Board!
00:42:45 Handling Player Piece Selections
00:56:00 Check Valid Piece Options
01:00:50 Calculate Valid Pawn Moves
01:08:10 Draw Valid Moves Onto the Screen
01:15:55 Calculate Valid Rook Moves
01:29:00 Calculate Valid Knight Moves
01:34:35 Calculate Valid Bishop Moves
01:38:10 Calculate Valid Queen Moves
01:40:52 Calculate Valid King Moves
01:43:39 Draw Captured Pieces onto the Screen
01:48:41 Check if King in Check and Flash on Screen
01:58:31 Checking for Winners and Game Over Handling
02:04:44 Restarting on Game Over

posted by bluesparrow2t