flutter: 增加走子的调试打印

This commit is contained in:
Calcitem 2020-11-17 01:29:02 +08:00
parent 3974f36868
commit 5096494372
2 changed files with 6 additions and 0 deletions

View File

@ -652,6 +652,7 @@ class Position {
// not in moveTable
if (md == moveDirectionNumber) {
print("putPiece: [$s] is not in [$currentSquare]'s moveTable");
return false;
}
}

View File

@ -98,7 +98,10 @@ class _BattlePageState extends State<BattlePage> {
//playSound(GAME_SOUND_DROG, position.side_to_move());
}
result = true;
print("putPiece: [$sq]");
break;
} else {
print("putPiece: skip [$sq]");
}
// break
@ -127,9 +130,11 @@ class _BattlePageState extends State<BattlePage> {
//
//playSound(GAME_SOUND_REMOVE, position.side_to_move());
result = true;
print("removePiece: [$sq]");
} else {
//
//playSound(GAME_SOUND_BANNED, position.side_to_move());
print("removePiece: skip [$sq]");
}
break;