// ************************* DEPLACEMENT PIECE ************************** private void DeplacerPiece(monBouton bori, monBouton bdest) { if ((piece.IsAtteignable(bdest.getNumLigne(), bdest.getNumCol()))) { bori.ImageSupp(); bori.Assombrir(); //CibleSup(bori, piece); piece.Deplacer(bdest.getNumLigne(), bdest.getNumCol()); bdest.ImageAj(piece.GetImg()); DD.FermerDispo(bdest.getNumLigne(), bdest.getNumCol()); //CibleAj(bdest, piece); } }
// ******************** MOUVEMENT JOUER ********************** private void DeplacerPiece(monBouton bori, monBouton bdest) { if ((piece.IsAtteignable(bdest.getNumLigne(), bdest.getNumCol()))) { bori.ImageSupp(); bori.Assombrir(); CibleSup(bori, piece); piece.Deplacer(bdest.getNumLigne(), bdest.getNumCol()); bdest.ImageAj(piece.GetImg()); DD.FermerDispo(bdest.getNumLigne(), bdest.getNumCol()); jouLig = bdest.getNumLigne(); jouCol = bdest.getNumCol(); dpl[cpClic] = bdest; ++cpClic; CibleAj(bdest, this.piece); } }