Cleaning
This commit is contained in:
parent
9e71bf4114
commit
719097fe69
16
src/Main.java
Normal file
16
src/Main.java
Normal file
@ -0,0 +1,16 @@
|
||||
import Comportements.ComportementAPiedAvecHache;
|
||||
import Comportements.ComportementParlerCommeUnePrincesse;
|
||||
|
||||
public class Main {
|
||||
public static void main(String[] args){
|
||||
SimulationJeu s = new SimulationJeu();
|
||||
s.creationPersonnages();
|
||||
System.out.println(s.afficheTous());
|
||||
System.out.println(s.emmetreUnSonTous());
|
||||
System.out.println(s.lancerCombar());
|
||||
s.changerComportementCombat(s.liste.get(0), new ComportementAPiedAvecHache());
|
||||
s.changerComportementEmmetreSon(s.liste.get(0), new ComportementParlerCommeUnePrincesse());
|
||||
System.out.println(s.emmetreUnSonTous());
|
||||
System.out.println(s.lancerCombar());
|
||||
}
|
||||
}
|
@ -23,11 +23,6 @@ public abstract class Personnage {
|
||||
public void setComportementEmmetreSon(ComportementEmmetreSon comportementEmmetreSon) {
|
||||
this.comportementEmmetreSon = comportementEmmetreSon;
|
||||
}
|
||||
|
||||
public ComportementEmmetreSon getComportementEmmetreSon() {
|
||||
return comportementEmmetreSon;
|
||||
}
|
||||
|
||||
public String EmmetreSon() {
|
||||
return this.comportementEmmetreSon.emmetreSon();
|
||||
}
|
||||
|
@ -1,7 +1,5 @@
|
||||
import Comportements.ComportementAPiedAvecHache;
|
||||
import Comportements.ComportementCombat;
|
||||
import Comportements.ComportementEmmetreSon;
|
||||
import Comportements.ComportementParlerCommeUnePrincesse;
|
||||
import Person.Chevalier;
|
||||
import Person.Fantasssin;
|
||||
import Person.Personnage;
|
||||
@ -60,17 +58,4 @@ public class SimulationJeu {
|
||||
}
|
||||
return result.toString();
|
||||
}
|
||||
|
||||
|
||||
public static void main(String[] args){
|
||||
SimulationJeu s = new SimulationJeu();
|
||||
s.creationPersonnages();
|
||||
System.out.println(s.afficheTous());
|
||||
System.out.println(s.emmetreUnSonTous());
|
||||
System.out.println(s.lancerCombar());
|
||||
s.changerComportementCombat(s.liste.get(0), new ComportementAPiedAvecHache());
|
||||
s.changerComportementEmmetreSon(s.liste.get(0), new ComportementParlerCommeUnePrincesse());
|
||||
System.out.println(s.emmetreUnSonTous());
|
||||
System.out.println(s.lancerCombar());
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user