diff --git a/src/variety/bonsan.js b/src/variety/bonsan.js index 906848671..6ab89a48e 100644 --- a/src/variety/bonsan.js +++ b/src/variety/bonsan.js @@ -378,6 +378,13 @@ return false; } + if ( + this.sidecell[0].path.departure.qnum === -2 || + this.sidecell[1].path.departure.qnum === -2 + ) { + return false; + } + var higher = this.sidecell[0].path.departure.anum === 0 ? 1 : 0; /* Difference in distance must be exactly 1 */ return ( @@ -457,6 +464,7 @@ component.clist.each(function(c) { c.distance = null; }); + component.clist.draw(); return; } @@ -465,6 +473,7 @@ num = num >= 0 ? num : isAnum ? 0 : this.board.cell.length; cell.distance = num; if (cell.lcnt === 0) { + cell.draw(); return; } @@ -494,6 +503,7 @@ dir = 3; } } + component.clist.draw(); } }, diff --git a/test/script/timebomb.js b/test/script/timebomb.js index cda6ab074..e228821aa 100644 --- a/test/script/timebomb.js +++ b/test/script/timebomb.js @@ -106,6 +106,19 @@ ui.debug.addDebugData("timebomb", { "mouse,left,1,1,9,1" ], result: "pzprv3/timebomb/1/5/3 . . . . /0 0 0 0 0 /1 1 1 0 /" + }, + { + label: "Allow merging qnum -2 lines", + input: [ + "ansclear", + "editmode", + "key,-", + "setconfig,dispmove,true", + "playmode", + "mouse,left,9,1", + "mouse,left,9,1,1,1" + ], + result: "pzprv3/timebomb/1/5/- . . . . /0 0 0 0 32 /1 1 1 1 /" } ] });