Hyperbola Quintessence in Rust

Welcome to my dev-blog series on writing a chess engine. This is part 3. Like always, suggestions are welcome! Hyperbola quintessence? This is the definition from chessprogramming.org: Hyperbola Quintessence applies the o^(o-2r)-trick also for vertical or diagonal negative Rays - by reversing the bit-order of up to one bit per rank or byte with a vertical flip aka x86-64 bswap. Why did I go for this approach? Because I thought magic bitboards were too hard for me....

October 18, 2022 · 5 min · 1022 words

Bitboards in Rust

Introduction Hello there! I haven’t posted in a while because I was working on my chess engine. Specifically, representing the pieces as bitboards. Now you may ask what a bitboard is. You can use bitboards to represent a chess board in a piece-centric manner. What is so special about bitboards then? Doesn’t a piece list do the same thing? Well, representing a bitboard only requires a single unsigned 64 bit integer!...

September 28, 2022 · 8 min · 1519 words

Yew.rs With TailwindCSS

Yew Like a lot of people, I think WASM is the future. Yew is an amazing frontend framework that helps in building web apps using WASM. It’s incredibly easy to use and the performance of the app is EXTREMELY fast! I’m currently re-writing Snowstry with yew.rs for the frontend (switching from NextJS). Here’s the repo link. Yew + Tailwind Setting up yew with tailwind was very easy as well. If you don’t know what tailwind is, here’s the link to their website....

August 12, 2022 · 2 min · 260 words

Writing a Build Automation Tool

After using GNU Make for automating the build step in my projects, I had this idea of making my own build automation tool like Make. I originally wanted to use Makefile-like syntax for the config file but instead settled with TOML after thinking about it for a while. I also used Rust to write this since I am kinda familiar with the language. Rust has a TOML crate for parsing TOML files....

July 8, 2022 · 3 min · 531 words

FEN String Parsing in Rust

I finally finished the FEN string parsing part of my chess engine after days of procrastinating and I just wanted to share my experience with everyone. So a FEN string looks like this: rnbqkbnr/pppppppp/8/8/8/8/PPPPPPPP/RNBQKBNR w KQkq - 0 1 This is the FEN string of the starting position in standard chess. It looks like random crap at first glance but this string conveys a lot of information. So let’s divide it into parts....

June 29, 2022 · 8 min · 1514 words