add elapsed move time commands to PGN exports

Fri, 17 Apr 2026 13:17:34 +0200

author
Mike Becker <universe@uap-core.de>
date
Fri, 17 Apr 2026 13:17:34 +0200
changeset 106
bdc9528d3e2b
parent 105
a991ea61f0e2
child 107
36dd94278142

add elapsed move time commands to PGN exports

resolves #822

src/chess/pgn.c file | annotate | diff | comparison | revisions
--- a/src/chess/pgn.c	Fri Apr 17 13:10:14 2026 +0200
+++ b/src/chess/pgn.c	Fri Apr 17 13:17:34 2026 +0200
@@ -212,6 +212,10 @@
             uint16_t clk = remaining_movetime2(gameinfo, gamestate, clkmv);
             print_clk(clk, clkstr, true);
             fprintf(stream, " {[%%clk %s]}", clkstr);
+            
+            /* elapsed move time */
+            print_clk(gamestate->moves[i].movetime.tv_sec, clkstr, true);
+            fprintf(stream, " {[%%emt %s]}", clkstr);
         }
         
         /* line break every 10 half-moves */

mercurial