txlyre 3 days ago
parent
commit
e523238cb0
1 changed files with 11 additions and 0 deletions
  1. 11 0
      chess0.py

+ 11 - 0
chess0.py

@@ -186,8 +186,19 @@ class ChessManager:
         self.sessions[id] = ChessSession(self.engine)
         self.sessions[id] = ChessSession(self.engine)
 
 
         if moves is not None:
         if moves is not None:
+            right = None
+
+            if "$$" in moves:
+                parts = moves.split("$$")
+
+                if len(parts) == 2:
+                    moves, right = parts
+              
             self.sessions[id].from_moves(moves, strict=strict)
             self.sessions[id].from_moves(moves, strict=strict)
 
 
+            if right:
+                session.from_moves(moves, strict=strict, reset=False)
+
     def end(self, id):
     def end(self, id):
         session = self.sessions.get(id)
         session = self.sessions.get(id)
         if not session:
         if not session: