Chess AI!

Chess AI!

by salvatoreicode

πŸ‘ 1 ❀️ 1 ⭐ 1 πŸ”„ 0
Created: Jun 13, 2025 Last modified: Jun 13, 2025 Shared: Jun 13, 2025

Instructions

Welcome to "Scratch Chess AI - Game of Kings". FAQs: - "There is a bug!" Unlikely, 875k visitors, no known issues. Consult experienced player, read instructions. - "Why invalid move?" Likely keeps / puts you in check. - "I still found a bug!" Please describe in detail, and click "Export", then copy & paste FEN (board) or PGN (moves) data into a comment. - "How to move?" Click piece, then click target square. - "Too difficult!" Switch to level Easy 1 or 2, at which the engine makes semi-random moves. - "Too easy!" Play level Difficult on TurboWarp (a Scratch runtime 50x faster than Scratch 3): https://turbowarp.org/148769358 If you win against level Difficult, please copy/paste PGN data for analysis (click "Export"). Scratch is not well suited for CPU-intense calculations (interpreted, missing language features like bitwise operations, slow by design), that is why a Scratch chess engine will always have limited playing strength. TurboWarp is faster, but still has to emulate Scratch, which slows it down. - "Too slow" The engine is think time bound, and takes exactly as long as designed. You can change think time on levels Medium and Difficult by pressing 't' and adjusting the custom think time value (in seconds). - "How to castle?" Move the king two squares towards the rook; king must not be in check, none of the passed squares must be attacked, and neither king nor rook must have moved before. - "Board is set up incorrectly" Maybe you mixed up king and queen. - "King and queen move the wrong way" Maybe you mixed up king and queen? - "King and rook moved at the same time" That's called 'castling', and is a valid move. - "Opponent pawn captured my pawn which had already passed it by moving two squares before!" That's called 'en-passant', and is a valid move. - "Why is it a draw when the engine mainly has its king left and I still have pieces?". Most likely draw by stalemate (no legal move but also not checked) - "How do I copy FEN or PGN data?" Click "Export", triple-click FEN or PGN data, press Ctrl-C (Windows) or right-click / select "Copy". - "How to play en-passant?" Move your pawn diagonally by one square, behind the opponent pawn which just moved two squares. - "What does the black/white bar on the right side of the board indicate?" It shows the current evaluation of the board, so either black's or white's lead in the game. Difficulty levels: - Easy 1: searches 1 ply, makes many deliberate mistakes - Easy 2: searches 1 ply, makes some deliberate mistakes - Blitz 1: searches 2 plies (4 on TurboWarp) plus subsequent captures / checks - Blitz 2: searches 3 to 4 plies (8 on TurboWarp) plus subsequent captures / checks - Medium: think time 15 seconds for midgame - Difficult: think time 25 seconds for midgame, 15 seconds for endgame. The fast TurboWarp runtime will add ca. 6 plies on Medium and Difficult, and roughly doubles the plies on Blitz 1+2. Press 't' for changing think time on levels Medium and Difficult Press 'd' for debugging info (evaluation, search depth, NPS, MPS) Press 'p' for profiler modes (Stats, time spent per function and search depth, number of transposition table hits) BUG REPORTS: Please describe exactly what happened, and provide exported board data: Click "Export", then look for the FEN data, select the text by triple-clicking it, copy it to the clipboard and paste it to the bug comment. Alternatively you can also export the move list in PGN format. Before you post a bug, go sure it really is a bug and not a misunderstanding, e.g. you may want to consult an experienced chess player beforehand.

Project Details

Visibility
Visible
Comments
Enabled
Remixed From
Project #148769358
Original Project
Project #148769358

More Cool Projects

Project thumbnail
View Project

beat up dog remix

by jakubko2010

Project thumbnail
View Project

NFL 2k 24 (with brodcasting) CJ Stroud cover

by vote929

Project thumbnail
View Project

fftjr #9 - tux paint

by penglingonafridge

Project thumbnail
View Project

SPRUN-GOOD

by the_hardmation

Project thumbnail
View Project

Beat Up LarryBoy

by everton_trader

Project thumbnail
View Project

Talking

by Alfie_Ben16

Project thumbnail
View Project

Animals Stampede

by animalslover44

Project thumbnail
View Project

abc lore video

by EmilioRules6416

Project thumbnail
View Project

Grow a Garden clicker

by SCRATCHMASTERSUS

Project thumbnail
View Project

Beat up One from TPoT (v1.1) remix

by bingbongboink

Project thumbnail
View Project

Add a button to beat up Nano 3 [remix 2]

by Super_Isaac_64

Project thumbnail
View Project

Trio Mashup fight (Alternate Title: Omnilotrio)

by Ink_Sans58

Project thumbnail
View Project

|| Ruler of Everything || Meme Template ||

by TDSlime

Project thumbnail
View Project

spring-platfomer γ€œζ˜₯ γƒ—γƒ©γƒƒγƒˆγƒ•γ‚©γƒΌγƒžγƒΌγ€œ

by kusowaroutan

Project thumbnail
View Project

Sonic The Hedgehog 4 on Scratch

by kakeaaron

Project thumbnail
View Project

Windows 7 Virus 2 (Short) remix

by Famous_666

Project thumbnail
View Project

15 minute timer

by jsmithgaming751

Project thumbnail
View Project

【θ‡ͺ動運軒】京ζ€₯η·šγ‚·γƒŸγƒ₯レーターv1.7.1/keikyu line drive simurator

by Takosumi_games

Project thumbnail
View Project

Super Mario vs OtherWorld V0.8

by DominicSCK

Project thumbnail
View Project

I LUV ROOMS (v1)

by Actuatr_

Project thumbnail
View Project

WINDOWS Beep

by Cozmo2016

Project thumbnail
View Project

Add characters crying cuz Mametchi crying

by ChamametchiArt

Project thumbnail
View Project

Beat Up Donkey Kong

by imnotaxiibuss123

Project thumbnail
View Project

Fionn2021 Rants #7 Bing (AKA Simon Ripoff)

by Fionn2021