Skip to content

Halma implementation broken? #77

Description

@gpiancastelli

The second rule of the Halma game in the canvas chapter states that you can make a legal move if you "[t]ake a piece and hop over an adjacent piece, and possibly repeat. That is, if you hop over an adjacent piece, then hop over another piece adjacent to your new position, that counts as a single move. In fact, any number of hops still counts as a single move."

Indeed, on the board, I can select the second piece in the last row, then click on the fourth cell in the last row and see the piece correctly moving. By my understanding of the cited second rule, a legal move would also be one where I select the first piece in the last row, then click on that same fourth cell in the last row. That is, instead of just one hop over an adjacent piece, it should be legal to "repeat" that kind of hop: two or more hops on adjacent pieces should be permitted. However, those two-hop move is not correctly recognized by the board, so the click on the fourth cell in the last row simply deselects the previously selected first piece in the last row. Shouldn't "any number of hops" still count "as a single move"?

Then again, I may be misunderstanding the game rules, so I hope someone can clarify this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions