Go to file
felixm 85ea0008fa Do not clone pieces to resolve #2. 2023-10-19 14:52:21 +02:00
.vscode Initial version of Talos Solver 2023-08-27 15:43:16 -04:00
src Do not clone pieces to resolve #2. 2023-10-19 14:52:21 +02:00
.gitignore Initial version of Talos Solver 2023-08-27 15:43:16 -04:00
Cargo.lock Initial version of Talos Solver 2023-08-27 15:43:16 -04:00
Cargo.toml Initial version of Talos Solver 2023-08-27 15:43:16 -04:00
LICENSE Add readme and license. 2023-08-27 15:47:06 -04:00
readme.md Add readme and license. 2023-08-27 15:47:06 -04:00

readme.md

The fantastic game The Talos Principle has these two dimensional Tetris like puzzles that I find annoying to solve. This program can solve them for me.

First, specify the field size and puzzle pieces:

fn main() {
    let field = Field::new(5, 5);
    let pieces = vec![
        // Piece::cleveland_z(), // -_
        // Piece::rhode_island_z(), // _-
        // Piece::teewee(),
        // Piece::hero(),
        // Piece::orange_ricky(), // ___|
        // Piece::blue_ricky(), // |___
        // Piece::smashboy(),
    ];
    let result = solve(field, pieces);
    match result {
        Some(field) => println!("{}", field),
        None => println!("No solution",)
    };
}

Then, get the solution with cargo run --release.