From 752d33ca71d906b8e6b71ded129c28b038328a28 Mon Sep 17 00:00:00 2001 From: michaelb Date: Sat, 11 Jul 2020 14:09:48 +0200 Subject: [PATCH] change human / bot position for more natural play --- src/shogiban.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/shogiban.rs b/src/shogiban.rs index d7241fb..d7a6d39 100644 --- a/src/shogiban.rs +++ b/src/shogiban.rs @@ -437,9 +437,9 @@ pub fn init() -> Result<(), String> { } }; - let human_turn = game.get_turn(); + let human_turn = !game.get_turn(); if human_turn { - human_play(&mut game); //for çnow, every turn is human + human_play(&mut game); } else { let mv = shogai::ai::greedy(&game); game = game.play_move(&mv);