File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed
Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -967,7 +967,10 @@ export class EmuGame extends GameBase {
967967 this . results = [ { type : "pass" } ] ;
968968 this . lastmove = "pass"
969969 } else {
970- this . results = [ ] ;
970+ console . log ( "Already the correct player" )
971+ // actually, don't clear the results
972+ // this will clobber the scoring
973+ // this.results = [];
971974 }
972975 this . currplayer = nextp ;
973976 // reset the game
@@ -1329,7 +1332,11 @@ export class EmuGame extends GameBase {
13291332 piece = pieces . find ( p => p . glyph === "c" + move . how )
13301333 }
13311334 if ( piece === undefined ) {
1332- throw new Error ( `Could not find the card to annotate (where: ${ move . where } , how: ${ move . how } ).\n${ JSON . stringify ( pieces ) } ` ) ;
1335+ // don't throw an error
1336+ // this can happen when ending a year and there's no intervening pass
1337+ // so just continue
1338+ continue ;
1339+ // throw new Error(`Could not find the card to annotate (where: ${move.where}, how: ${move.how}).\n${JSON.stringify(pieces)}`);
13331340 }
13341341 const xStart = piece . x - halfUnit ;
13351342 const yStart = piece . y - halfUnit ;
You can’t perform that action at this time.
0 commit comments