Skip to content

Commit

Permalink
指し手のコメント対応
Browse files Browse the repository at this point in the history
  • Loading branch information
TadaoYamaoka committed Jan 18, 2023
1 parent b76edb3 commit efcb5ad
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions cshogi/KI2.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,13 @@ def parse_str(kif_str):
if len(line) == 0:
pass
elif line[0] == "*":
if line[:2] == "**":
if len(moves) > 0:
if len(moves) - len(comments) > 1:
comments.extend([None]*(len(moves) - len(comments) - 1))
comments.append(line[2:])
if line[:2] == "**":
comments.append(line[2:])
else:
comments.append(line[1:])
else:
header_comments.append(line[1:])
elif ':' in line:
Expand Down

0 comments on commit efcb5ad

Please sign in to comment.