删除未使用代码
This commit is contained in:
parent
aab9b43fe0
commit
a158249f23
@ -444,7 +444,7 @@ export default {
|
||||
|
||||
// 查获胜条件
|
||||
checkWinner(row, col) {
|
||||
const player = this.board[row][col].player
|
||||
// const player = this.board[row][col].player
|
||||
let hasFiveInRow = false
|
||||
let winningPositions = []
|
||||
|
||||
@ -567,11 +567,6 @@ export default {
|
||||
|
||||
// 验证获胜棋子
|
||||
validateWinningPieces(pieces, player) {
|
||||
const validation = pieces.map(([row, col]) => ({
|
||||
position: [row, col],
|
||||
valid: this.isValidPosition(row, col),
|
||||
piece: this.board[row][col],
|
||||
}))
|
||||
return pieces.every(([row, col]) => {
|
||||
return this.isValidPosition(row, col) && this.board[row][col].player === player
|
||||
})
|
||||
|
Loading…
Reference in New Issue
Block a user