fix
This commit is contained in:
parent
63e800bd1c
commit
cf60dd752d
|
@ -90,8 +90,7 @@ function playingAT(cellKey){
|
||||||
var symbol="O";
|
var symbol="O";
|
||||||
}
|
}
|
||||||
grid[cellKey]=symbol;
|
grid[cellKey]=symbol;
|
||||||
alert (cellKey);
|
document.getElementById(cellKey).innerHTML = symbol;
|
||||||
document.getElementById[cellKey].innerHTML = symbol;
|
|
||||||
|
|
||||||
addLog("Player " + currentPlayer + " joue " + cellKey);
|
addLog("Player " + currentPlayer + " joue " + cellKey);
|
||||||
//does he win?
|
//does he win?
|
||||||
|
@ -107,6 +106,7 @@ function playingAT(cellKey){
|
||||||
|| ((grid['0-2'] == grid['1-1']) && (grid['1-1'] == grid['2-0']) && (grid['2-0']!==""))
|
|| ((grid['0-2'] == grid['1-1']) && (grid['1-1'] == grid['2-0']) && (grid['2-0']!==""))
|
||||||
){
|
){
|
||||||
addLog("Player " + currentPlayer + "gagne la partie");
|
addLog("Player " + currentPlayer + "gagne la partie");
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//change player
|
//change player
|
||||||
|
|
Loading…
Reference in New Issue
Block a user