Recherche d'objets et personnage avec la portee.

This commit is contained in:
aminecmi 2015-02-01 10:33:56 +01:00
parent bcd693aba7
commit 6e4e647866
12 changed files with 150 additions and 353 deletions

View File

@ -25,24 +25,24 @@ public abstract class CaseAbstraite {
} }
public void generateVoisins(CaseAbstraite[][] plateau) { public void generateVoisins(CaseAbstraite[][] plateau) {
for (int i = coord.getHor() - 1; i < coord.getHor() + 1; i++) { for (int i = coord.getLigne() - 1; i <= coord.getLigne() + 1; i++) {
for (int j = coord.getVert() - 1; j < coord.getVert() + 1; j++) { for (int j = coord.getCol() - 1; j <= coord.getCol() + 1; j++) {
if (i > 0 && i < plateau.length && j > 0 && j < plateau[0].length) { if (i >= 0 && i < plateau.length && j >= 0 && j < plateau[0].length) {
if (i == coord.getHor() && j < coord.getVert()) { if (i < coord.getLigne() && j == coord.getCol()) {
voisins.put(PointsCardinaux.N, plateau[i][j]); voisins.put(PointsCardinaux.N, plateau[i][j]);
} else if (i > coord.getHor() && j < coord.getVert()) { } else if (i < coord.getLigne() && j > coord.getCol()) {
voisins.put(PointsCardinaux.NE, plateau[i][j]); voisins.put(PointsCardinaux.NE, plateau[i][j]);
} else if (i > coord.getHor() && j == coord.getVert()) { } else if (i == coord.getLigne() && j > coord.getCol()) {
voisins.put(PointsCardinaux.E, plateau[i][j]); voisins.put(PointsCardinaux.E, plateau[i][j]);
} else if (i > coord.getHor() && j > coord.getVert()) { } else if (i > coord.getLigne() && j > coord.getCol()) {
voisins.put(PointsCardinaux.NE, plateau[i][j]); voisins.put(PointsCardinaux.SE, plateau[i][j]);
} else if (i == coord.getHor() && j > coord.getVert()) { } else if (i > coord.getLigne() && j == coord.getCol()) {
voisins.put(PointsCardinaux.S, plateau[i][j]); voisins.put(PointsCardinaux.S, plateau[i][j]);
} else if (i < coord.getHor() && j > coord.getVert()) { } else if (i > coord.getLigne() && j < coord.getCol()) {
voisins.put(PointsCardinaux.SW, plateau[i][j]); voisins.put(PointsCardinaux.SW, plateau[i][j]);
} else if (i < coord.getHor() && j == coord.getVert()) { } else if (i == coord.getLigne() && j < coord.getCol()) {
voisins.put(PointsCardinaux.W, plateau[i][j]); voisins.put(PointsCardinaux.W, plateau[i][j]);
} else if (i < coord.getHor() && j < coord.getVert()) { } else if (i < coord.getLigne() && j < coord.getCol()) {
voisins.put(PointsCardinaux.NW, plateau[i][j]); voisins.put(PointsCardinaux.NW, plateau[i][j]);
} }
} }

View File

@ -1,27 +1,27 @@
package Cases; package Cases;
public class Coordonnees { public class Coordonnees {
private int vert; private int col;
private int hor; private int ligne;
public Coordonnees(int vert, int hor) { public Coordonnees(int vert, int hor) {
this.vert = vert; this.col = vert;
this.hor = hor; this.ligne = hor;
} }
public int getVert() { public int getLigne() {
return vert; return ligne;
} }
public void setVert(int vert) { public void setLigne(int ligne) {
this.vert = vert; this.ligne = ligne;
} }
public int getHor() { public int getCol() {
return hor; return col;
} }
public void setHor(int hor) { public void setCol(int col) {
this.hor = hor; this.col = col;
} }
} }

View File

@ -10,9 +10,5 @@ public abstract class EtatPersonnageAbstrait {
this.joueur = perso; this.joueur = perso;
} }
public abstract void AnalyseJoueur(); protected abstract void execute();
public abstract void ExecutionJoueur();
public abstract void ConflitJoueur();
public abstract void mediationConflits();
} }

View File

@ -1,37 +0,0 @@
package Etats;
import Person.Personnage;
public class EtatPersonnageCombattant extends EtatPersonnageAbstrait {
//Etat d'un personnage avec un marteau, cible les joueurs et ignore le reste.
protected EtatPersonnageCombattant(Personnage perso) {
super(perso);
// TODO Auto-generated constructor stub
}
@Override
public void AnalyseJoueur() {
// TODO Auto-generated method stub
}
@Override
public void ExecutionJoueur() {
// TODO Auto-generated method stub
}
@Override
public void ConflitJoueur() {
// TODO Auto-generated method stub
}
@Override
public void mediationConflits() {
}
}

View File

@ -8,37 +8,12 @@ public class EtatPersonnageKO extends EtatPersonnageAbstrait {
public EtatPersonnageKO(Personnage perso) { public EtatPersonnageKO(Personnage perso) {
super(perso); super(perso);
// TODO Auto-generated constructor stub
this.nbTourKO = 3;
}
@Override
public void AnalyseJoueur() {
// TODO Auto-generated method stub
}
@Override
public void ExecutionJoueur() {
// TODO Auto-generated method stub
nbTourKO--;
if (nbTourKO==0){
this.joueur.ChangeEtat(EEtat.EtatOK);
}
}
@Override
public void ConflitJoueur() {
// TODO Auto-generated method stub
} }
@Override @Override
public void mediationConflits() { protected void execute() {
if (this.joueur.getPointsDeVie() > 0) {
this.joueur.ChangeEtat(EEtat.EtatOK);
}
} }
} }

View File

@ -1,72 +1,21 @@
package Etats; package Etats;
import Comportements.*;
import Person.Personnage; import Person.Personnage;
public class EtatPersonnageOK extends EtatPersonnageAbstrait { public class EtatPersonnageOK extends EtatPersonnageAbstrait {
private ComportementAction Action; private int nbTourKO;
public EtatPersonnageOK(Personnage perso) { public EtatPersonnageOK(Personnage perso) {
super(perso); super(perso);
// TODO Auto-generated constructor stub this.nbTourKO = 3;
this.ChangerAction(EAction.SeDeplacer);
} }
@Override
public void AnalyseJoueur() {
// TODO Auto-generated method stub
}
@Override
public void ExecutionJoueur() {
// TODO Auto-generated method stub
Action.executerAction(this.joueur);
}
@Override
public void ConflitJoueur() {
// TODO Auto-generated method stub
}
@Override @Override
public void mediationConflits() { protected void execute() {
if (this.joueur.getPointsDeVie() == 0) {
this.joueur.ChangeEtat(EEtat.EtatKO);
}
} }
public void ChangerAction(EAction nouvelAction) {
switch(nouvelAction)
{
case ChangerCouleurCase:
Action = new ComportementActionChangerCouleurCase();
break;
case RamasserNeige:
Action = new ComportementActionRamasserNeige();
break;
case SeDeplacer:
Action = new ComportementActionSeDeplacer();
break;
case TirerBalon:
Action = new ComportementActionTirerBalon();
break;
case TirerBouleDeNeige:
Action = new ComportementActionTirerBouleDeNeige();
break;
//case Null:
//Action = null;
//break;
default:
break;
}
this.joueur.setAction(nouvelAction);
}
} }

View File

@ -14,14 +14,14 @@ public class FabriquePersonnagesBattleZone extends FabriquePersonnagesAbstraite
public ArrayList<Personnage> CreerPersonages(Organisation o) { public ArrayList<Personnage> CreerPersonages(Organisation o) {
ArrayList<Personnage> list = new ArrayList<Personnage>(); ArrayList<Personnage> list = new ArrayList<Personnage>();
PersonnageBattleZone p1 = new PersonnageBattleZone("Bob", 100.0, 1.0, 1.0, parDefaut); PersonnageBattleZone p1 = new PersonnageBattleZone("Bob", 100.0, 1.0, 1.0, 2, parDefaut);
list.add(p1); list.add(p1);
PersonnageBattleZone p2 = new PersonnageBattleZone("Jo", 100.0, 1.0, 1.0, parDefaut); //PersonnageBattleZone p2 = new PersonnageBattleZone("Jo", 100.0, 1.0, 1.0, 2, parDefaut);
list.add(p2); //list.add(p2);
PersonnageBattleZone p3 = new PersonnageBattleZone("Max", 100.0, 1.0, 1.0, parDefaut); //PersonnageBattleZone p3 = new PersonnageBattleZone("Max", 100.0, 1.0, 1.0, 2, parDefaut);
list.add(p3); //list.add(p3);
PersonnageBattleZone p4 = new PersonnageBattleZone("Zac", 100.0, 1.0, 1.0, parDefaut); //PersonnageBattleZone p4 = new PersonnageBattleZone("Zac", 100.0, 1.0, 1.0, 2, parDefaut);
list.add(p4); //list.add(p4);
return list; return list;
} }
} }

View File

@ -2,8 +2,7 @@ package Person;
import Cases.CaseAbstraite; import Cases.CaseAbstraite;
import Cases.PointsCardinaux; import Cases.PointsCardinaux;
import Comportements.ComportementAction; import Comportements.*;
import Comportements.EAction;
import Composition.PersonnagesAbstraits; import Composition.PersonnagesAbstraits;
import Etats.EEtat; import Etats.EEtat;
import Etats.EtatPersonnageAbstrait; import Etats.EtatPersonnageAbstrait;
@ -11,7 +10,9 @@ import Etats.EtatPersonnageKO;
import Etats.EtatPersonnageOK; import Etats.EtatPersonnageOK;
import Objets.ObjetAbstrait; import Objets.ObjetAbstrait;
import java.util.ArrayList;
import java.util.HashMap; import java.util.HashMap;
import java.util.HashSet;
public class Personnage extends PersonnagesAbstraits { public class Personnage extends PersonnagesAbstraits {
@ -22,33 +23,38 @@ public class Personnage extends PersonnagesAbstraits {
protected double pointsDeVie; protected double pointsDeVie;
protected double force; protected double force;
protected double vitesse; protected double vitesse;
protected double porter; protected double portee;
protected EAction action; protected EAction action;
private EtatPersonnageAbstrait etatCourant; protected ComportementAction Action;
private EtatPersonnageAbstrait etatCourant;
private HashMap<PointsCardinaux, CaseAbstraite> voisins; private HashMap<PointsCardinaux, CaseAbstraite> voisins;
protected Personnage(String name, ComportementAction c) {
this.nom = name; protected Personnage(String name, ComportementAction c) {
this.nom = name;
this.pointsDeVie = 100; this.pointsDeVie = 100;
this.force = 10; this.force = 10;
this.vitesse = 1; this.vitesse = 1;
this.porter = 2; this.portee = 2;
this.caseCourante = null; this.caseCourante = null;
this.etatCourant = new EtatPersonnageOK(this); this.etatCourant = new EtatPersonnageOK(this);
this.action = EAction.Null; this.ChangerAction(EAction.SeDeplacer);
}
protected Personnage(String name, double lifePoint, double strength, double speed, ComportementAction a) { }
this.nom = name;
protected Personnage(String name, double lifePoint, double strength, double speed, int portee, ComportementAction a) {
this.nom = name;
this.pointsDeVie=lifePoint; this.pointsDeVie=lifePoint;
this.force=strength; this.force=strength;
this.vitesse=speed; this.vitesse=speed;
this.portee = portee;
this.caseCourante=null; this.caseCourante=null;
this.etatCourant= new EtatPersonnageOK(this); this.etatCourant= new EtatPersonnageOK(this);
this.action = EAction.Null; this.ChangerAction(EAction.SeDeplacer);
}
}
public void ChangeEtat(EEtat NouvelEtat) public void ChangeEtat(EEtat NouvelEtat)
@ -127,13 +133,13 @@ public class Personnage extends PersonnagesAbstraits {
} }
public double getPorter() { public double getPortee() {
return porter; return portee;
} }
public void setPorter(double porter) { public void setPortee(double portee) {
this.porter = porter; this.portee = portee;
} }
public EAction getAction() { public EAction getAction() {
return action; return action;
@ -144,188 +150,97 @@ public class Personnage extends PersonnagesAbstraits {
} }
public void AnalyseSituation() { public void AnalyseSituation() {
etatCourant.AnalyseJoueur(); ArrayList<ObjetAbstrait> objets = rechercheObjetProche();
ArrayList<Personnage> personnages = rechercheJoueur();
} }
public void Execution() { public void Execution() {
etatCourant.ExecutionJoueur(); Action.executerAction(this);
} }
public void ResoudreLesConflits(){ public void ResoudreLesConflits(){
etatCourant.ConflitJoueur();
} }
public ObjetAbstrait rechercheObjetProche() { public HashMap<PointsCardinaux, CaseAbstraite> voisinsPortee(CaseAbstraite c, int rayon) {
HashMap<PointsCardinaux, CaseAbstraite> voisinsActuels = new HashMap<PointsCardinaux, CaseAbstraite>();
HashMap<PointsCardinaux, CaseAbstraite> v = c.getVoisins();
if ((rayon + 1) == this.getPortee()) {
// voisinsActuels.putAll(v);
return c.getVoisins();
} else {
int r = rayon + 1;
for (PointsCardinaux mapKey : v.keySet()) {
voisinsActuels.putAll(voisinsPortee(v.get(mapKey), r));
}
return voisinsActuels;
}
}
ObjetAbstrait objetDeLaCase = null; public ArrayList<ObjetAbstrait> rechercheObjetProche() {
for (PointsCardinaux mapKey : voisins.keySet()) { ArrayList<ObjetAbstrait> objetsVoisins = new ArrayList<ObjetAbstrait>();
if (voisins.get(mapKey).getObjetOccupant() != null) {
objetDeLaCase = voisins.get(mapKey).getObjetOccupant(); HashSet<CaseAbstraite> voisinsDesVoisins = getCaseAbstraitesForPortee();
for (CaseAbstraite c : voisinsDesVoisins) {
if (c.getObjetOccupant() != null) {
objetsVoisins.add(c.getObjetOccupant());
} }
} }
if (objetDeLaCase != null) { return objetsVoisins;
for (PointsCardinaux mapKey : voisins.keySet()) { }
switch (mapKey) {
case N:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getObjetOccupant();
}
break;
case NE:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.NE) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.NE).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getObjetOccupant();
}
break;
case E:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getObjetOccupant();
}
break;
case SE:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.SE) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.SE).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getObjetOccupant();
}
break;
case S:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getObjetOccupant();
}
break;
case SW:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.SW) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.SW).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getObjetOccupant();
}
break;
case W:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getObjetOccupant();
}
break;
case NW:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.NW) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.NW).getObjetOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
objetDeLaCase = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getObjetOccupant();
}
break;
default:
break;
} protected HashSet<CaseAbstraite> getCaseAbstraitesForPortee() {
} HashSet<CaseAbstraite> voisinsDesVoisins = new HashSet<CaseAbstraite>();
} voisinsDesVoisins.addAll(voisinsPortee(this.caseCourante, 0).values());
return objetDeLaCase; return voisinsDesVoisins;
} }
public Personnage rechercheJoueur() { public ArrayList<Personnage> rechercheJoueur() {
Personnage personne = null; ArrayList<Personnage> personnes = new ArrayList<Personnage>();
for (PointsCardinaux mapKey : voisins.keySet()) { HashSet<CaseAbstraite> voisinsDesVoisins = getCaseAbstraitesForPortee();
if (voisins.get(mapKey).getOccupant() != null) {
personne = voisins.get(mapKey).getOccupant(); for (CaseAbstraite c : voisinsDesVoisins) {
if (c.getOccupant() != null) {
personnes.add(c.getOccupant());
} }
} }
if (personne != null) {
for (PointsCardinaux mapKey : voisins.keySet()) {
switch (mapKey) {
case N:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getOccupant();
}
break;
case NE:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.NE) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.NE).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getOccupant();
}
break;
case E:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getOccupant();
}
break;
case SE:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.E) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.E).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.SE) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.SE).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getOccupant();
}
break;
case S:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getOccupant();
}
break;
case SW:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.S) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.S).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.SW) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.SW).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getOccupant();
}
break;
case W:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getOccupant();
}
break;
case NW:
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.W) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.W).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.NW) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.NW).getOccupant();
}
if (voisins.get(mapKey).getVoisins().get(PointsCardinaux.N) != null) {
personne = voisins.get(mapKey).getVoisins().get(PointsCardinaux.N).getOccupant();
}
break;
default:
break;
} return personnes;
}
}
return personne;
} }
public void mediationConflits() { public void mediationConflits() {
etatCourant.mediationConflits();
}
public void ChangerAction(EAction nouvelAction) {
switch (nouvelAction) {
case ChangerCouleurCase:
Action = new ComportementActionChangerCouleurCase();
break;
case RamasserNeige:
Action = new ComportementActionRamasserNeige();
break;
case SeDeplacer:
Action = new ComportementActionSeDeplacer();
break;
case TirerBalon:
Action = new ComportementActionTirerBalon();
break;
case TirerBouleDeNeige:
Action = new ComportementActionTirerBouleDeNeige();
break;
default:
break;
}
this.setAction(nouvelAction);
} }
} }

View File

@ -4,9 +4,9 @@ import Comportements.ComportementAction;
public class PersonnageBattleGoal extends Personnage { public class PersonnageBattleGoal extends Personnage {
protected PersonnageBattleGoal(String name, double lifePoint, double strength, double speed, ComportementAction parDefaut) { protected PersonnageBattleGoal(String name, double lifePoint, double strength, double speed, int portee, ComportementAction parDefaut) {
super(name, lifePoint, strength, speed, parDefaut); super(name, lifePoint, strength, speed, portee, parDefaut);
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
} }

View File

@ -4,9 +4,9 @@ import Comportements.ComportementAction;
public class PersonnageBattleSnow extends Personnage{ public class PersonnageBattleSnow extends Personnage{
protected PersonnageBattleSnow(String name, double lifePoint, double strength, double speed, ComportementAction parDefaut) { protected PersonnageBattleSnow(String name, double lifePoint, double strength, double speed, int portee, ComportementAction parDefaut) {
super(name, lifePoint, strength, speed, parDefaut); super(name, lifePoint, strength, speed, portee, parDefaut);
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub
} }
} }

View File

@ -8,8 +8,8 @@ import java.util.Random;
public class PersonnageBattleZone extends Personnage { public class PersonnageBattleZone extends Personnage {
Color couleur; Color couleur;
public PersonnageBattleZone(String name, double lifePoint, double strength, double speed, ComportementAction parDefaut) { public PersonnageBattleZone(String name, double lifePoint, double strength, double speed, int portee, ComportementAction parDefaut) {
super(name, lifePoint, strength, speed, parDefaut); super(name, lifePoint, strength, speed, portee, parDefaut);
// TODO Auto-generated constructor stub // TODO Auto-generated constructor stub

View File

@ -48,14 +48,13 @@ public class SimulationJeu {
boolean continuer = true; boolean continuer = true;
while (continuer) { while (continuer) {
afficheTous();
for (Personnage p : personnages) { for (Personnage p : personnages) {
p.AnalyseSituation(); p.AnalyseSituation();
p.Execution(); p.Execution();
mediationDesConflits(); // utiliser le pattern avec l'historique pour les actions. On pourra faire un retour arrière si conflit + réexecturer mediationDesConflits(); // utiliser le pattern avec l'historique pour les actions. On pourra faire un retour arrière si conflit + réexecturer
recupererInformations(); recupererInformations();
} }
afficheTous();
// bloquer le tour jusqu'a toucher une touche du clavier. // bloquer le tour jusqu'a toucher une touche du clavier.
Scanner s = new Scanner(System.in); Scanner s = new Scanner(System.in);