correction pion vite fait + reines bonnes coordonnées
This commit is contained in:
parent
e2d8fcf7af
commit
fed94934c3
@ -51,11 +51,11 @@ public class Echiquier {
|
||||
private Fou FouN1 = new Fou("Noir","FN",new Position(3,8));
|
||||
private Fou FouN2 = new Fou("Noir","FN",new Position(6,8));
|
||||
|
||||
private Reine ReineB1 = new Reine("Blanc","QB",new Position(5,1));
|
||||
private Reine ReineN1 = new Reine("Noir","QN",new Position(5,8));
|
||||
private Reine ReineB1 = new Reine("Blanc","QB",new Position(4,1));
|
||||
private Reine ReineN1 = new Reine("Noir","QN",new Position(4,8));
|
||||
|
||||
private Roi RoiB1 = new Roi("Blanc","KB",new Position(4,1));
|
||||
private Roi RoiN1 = new Roi("Noir","KN",new Position(4,8));
|
||||
private Roi RoiB1 = new Roi("Blanc","KB",new Position(5,1));
|
||||
private Roi RoiN1 = new Roi("Noir","KN",new Position(5,8));
|
||||
|
||||
//remplissage de l'echiquier
|
||||
private Piece[][] echiquier =
|
||||
|
@ -14,7 +14,7 @@ public class Pion extends Piece {
|
||||
{
|
||||
if (p.getPosition().getX()-1 == this.getPosition().getX() || p.getPosition().getX()+1 == this.getPosition().getX()) //Verification si la personne souhaite manger la piece
|
||||
{
|
||||
if ((this.getCouleur().equals("Blanc") && p.getPosition().getY()-1 == this.getPosition().getY()) || (this.getCouleur() == "noir" && p.getPosition().getY()+1 == this.getPosition().getY()))
|
||||
if ((this.getCouleur().equals("Blanc") && p.getPosition().getY()-1 == this.getPosition().getY()) || (this.getCouleur() == "Noir" && p.getPosition().getY()+1 == this.getPosition().getY()))
|
||||
{
|
||||
if (p.getNom().equals(".."))
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user