gunyarakun / python-shogi

A pure Python shogi library with move generation and validation and handling of common formats.
GNU General Public License v3.0
179 stars 43 forks source link

Feature: Allow for custom starting boards through kif files (Issue #24) #37

Closed DerAndereJohannes closed 3 years ago

DerAndereJohannes commented 3 years ago

Feature description

Addition to the kif parser that imports the custom starting board as sfen (perfect for tsume problems) as discussed in issue #24 .

Need help with some information:

as of right now, i have that the custom sfen uses the current_turn variable as whos turn it is and just the number 1 as turn number. Is this the correct way of doing it? In other words, what should the turn variable and the move variable be for the sfen? Either:

  1. turn = 'b', move = 1 to signify the start of the game
  2. turn = current_turn, move = len(moves) to signify where the game will be after using all the moves

Thanks in advance!

coveralls commented 3 years ago

Coverage Status

Coverage increased (+0.8%) to 83.269% when pulling 6bcd055d876c3a7685348bd44aa306d82e2b401d on DerAndereJohannes:kif-import-starting-sfen into 2f4d6d9219c35a2b94fcdede26883f2804c2cfd3 on gunyarakun:master.

gunyarakun commented 3 years ago

@DerAndereJohannes Sorry for my late response. A great job!

gunyarakun commented 3 years ago

@DerAndereJohannes Could you rebase the pull request with master? My de-escaping Japanese characters affects your pull request. Thank you in advance!

DerAndereJohannes commented 3 years ago

Sorry for my late response. I am having trouble understanding what you mean. I made sure that my branch was up to date with your master repository & branch and github is seeing no conflicts. Please tell me what to change so that I can be of most help!

Thank you and sorry for any inconvenience.

gunyarakun commented 3 years ago

Thank you for your response, @DerAndereJohannes. I would like just to resolve the conflict to merge your pull request. image

DerAndereJohannes commented 3 years ago

I am very confused as to why this is happening. when attempting to rebase, the 'conflict' shows code that no longer exists anywhere.. i might just make a new branch and copy the added code over..

DerAndereJohannes commented 3 years ago

I will create a new pull request with the new information.

gunyarakun commented 3 years ago

@DerAndereJohannes I appreciate you! I'll take a look of your new pull request.