Skip to content

Commit 2fb5d66

Browse files
alweyilaripih
authored andcommitted
CECP engine forfeits on claim of illegal move
As long as cutechess has an arbiter function, illegal moves are not (read: should not be) transmitted to engines. So a claim of an illegal move should not be valid. At present, without adjudication the engine waits and finally forfeits on time.
1 parent d21a323 commit 2fb5d66

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

projects/lib/src/xboardengine.cpp

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -759,6 +759,13 @@ void XboardEngine::parseLine(const QString& line)
759759
pos += rx.matchedLength();
760760
}
761761
}
762+
else if (command.startsWith("Illegal"))
763+
{
764+
forfeit(Chess::Result::Adjudication,
765+
tr("%1 claims illegal %2")
766+
.arg(this->side().toString())
767+
.arg(args));
768+
}
762769
else if (command == "Error")
763770
{
764771
// If the engine complains about an unknown result command,

0 commit comments

Comments
 (0)