|
@ -22,8 +22,11 @@ public class cell extends JButton { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
protected void OnMouseClick() { |
|
|
protected void OnMouseClick() { |
|
|
|
|
|
if(value == 0) { |
|
|
value = ttt.player; |
|
|
value = ttt.player; |
|
|
ttt.endTurn(); |
|
|
ttt.endTurn(); |
|
|
|
|
|
setEnabled(false); |
|
|
|
|
|
|
|
|
switch (value) { |
|
|
switch (value) { |
|
|
case 1: setBackground(new Color(255,0,0)); |
|
|
case 1: setBackground(new Color(255,0,0)); |
|
|
break; |
|
|
break; |
|
@ -33,6 +36,7 @@ public class cell extends JButton { |
|
|
break; |
|
|
break; |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|