Take Back Retro Engine + Engine x Engine?

81 views
Skip to first unread message

waldomiro dias machado junior

unread,
Dec 17, 2025, 11:02:07 AM12/17/25
to pico...@googlegroups.com
Dear developers, 

Would it be possible to make the "Take back" function work in Retro Engines? 

Would it be feasible to choose two engines and have them play against each other so we can follow the match in PicoChess?

Regards, Waldomiro 

Em domingo, 14 de dezembro de 2025, RandyR <randy...@gmail.com> escreveu:
Note that you will need to run the following commands in the /opt/picochess folder prior to starting picochess after pulling the changes in order to get the new python modules:

source venv/bin/activate
pip3 install --upgrade pip
pip3 install --upgrade -r requirements.txt
deactivate

Then you can run:

sudo systemctl start picochess

(Another option is to re-run the installation script "./install-picochess.sh pico"

Randy

On Sunday, December 14, 2025 at 2:22:19 AM UTC-6 messi...@gmail.com wrote:
I have now merged this branch to master, so testing can continue in master branch.
To get back to master do this (happy path):
cd /opt/picochess
sudo systemctl stop picochess
git fetch origin
git checkout master
git pull --ff-only origin master
sudo systemctl start picochess

If you are "stuck" and need to force your /opt/picochess into exactly same as latest master code:
cd /opt/picochess
sudo systemctl stop picochess
git fetch origin
git checkout master
git reset --hard origin/master
sudo systemctl start picochess

The reset --hard will always give you the latest master code and overwrite any local code changes you have.

When I have time I could look at the Chesslink retry-connection code and make it a separate async background task so that the menu will not be stuck while Chesslink is reconnecting...

--
You received this message because you are subscribed to the Google Groups "PicoChess" group.
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+unsubscribe@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/picochess/d98784b7-5108-4c48-add2-043bfbd9e4e9n%40googlegroups.com.

Dirk

unread,
Dec 20, 2025, 5:44:44 AM12/20/25
to PicoChess
Hi Waldomiro,

regarding the possibility of a retro take back function: 

Nope - at least for the moment.

The problem is that each mame/retro engine does have a different mechanism to take back moves (for some it is sufficient to take back the move on the board -if this exists- others do require a specific key to be pressed etc.

For this you would have to enhance each of the plugins for the specific machine. And even then it would n to be sufficient because there is no uci command (the interface protocol PicoChess uses to communicate with the engines) to do this tack back (only in WinBoard protocol I think).

So there would be only one uci compatible solution: send just the new position (after takle back) to the engine like PicoChess does for real uci engines.
But for this ALL engine would have to support the position set up feature and would have to support correct castling rights, en passant possibilities etc. which is not fully supported yet.

But at least you can use the "pseudo blunder take back" function I have implemented by activating the tutor (watcher). Then in case of a blinder you get the chance to take back your move. This is possible because the blunder is checked before the move is send to the engine.

If that is not sufficient for you see it that way: taking back moves is not an official rule and we shouldn't cheat on our old friendly retro engines, shouldn't we? ;-)))))))))))))

Dirk 

waldomiro dias machado junior

unread,
Dec 20, 2025, 6:41:01 AM12/20/25
to pico...@googlegroups.com
Hi Dirk, 

Thank you so much for your reply, you helped me a lot! I'm going to use this function to see if I don't ruin some good games. 

I know that using the Take Back function is cheating, but it's very useful for studying a game that was going very well and I make a serious mistake and ruin everything. 

I'm a collector of old chess machines and I only improved my game when I stopped using this function and started respecting the game time; I always liked playing at the total game in 15 or 30 minute levels.

Anyway, the idea isn't to cheat, it was to study lines of play where I could find a winning variation.

Again, thank you very much for the excellent explanation! 

Waldomiro.

--
You received this message because you are subscribed to the Google Groups "PicoChess" group.
To unsubscribe from this group and stop receiving emails from it, send an email to picochess+...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/picochess/341051b4-eea1-4e26-9f9b-9b89ae498339n%40googlegroups.com.

Johan Sjöblom

unread,
Dec 20, 2025, 10:27:01 AM12/20/25
to PicoChess
Yes, Dirk have implemented a function that if the tutor gives a blunder "??" the picochesslogic does not send the move to the retro engine and instead does an automatic takeback before sending the move. The retro engines don't have support for takeback after the move has been sent (just like described in Dirks answer)

When it comes to having two engines playing against each other that is not trivial, but its not impossible either. I would do it very much the same as Dirks logic with the PGN Replay engine where there is actually a hidden "side switch" after each move so that the PGN Replay engine keeps playing for both sides. That could be one way to get closer to a situation where you could pick up another engine and picochess would keep switching sides and while doing the side-switch also switch the engine. Then no user move logic would kick in, so that could be a feasible. We would need some kind of "mode" for that resembling the pgn_mode.

At the moment I think I need to focus on fixing V4 so that it works as well and stable as V3 and covers the same functionality.

-- Johan

waldomiro dias machado junior

unread,
Dec 20, 2025, 10:50:28 AM12/20/25
to pico...@googlegroups.com
Hello Johan, 

Thank you very much for your reply. 

After you resolve all the improvements in version 4 and it becomes as stable as version 3, if one day it's possible to add the option to choose two engines and watch matches between them, it will be fantastic!

Congratulations to all of you for the excellent work you do at PicoChess!

Waldomiro.

Reply all
Reply to author
Forward
0 new messages