Se réveler JoueurVirtuel
This commit is contained in:
@ -58,8 +58,30 @@ public class ActionAltererStatistiquesJoueur extends Action{
|
||||
this.valeur = valeur;
|
||||
}
|
||||
|
||||
public String getKey() {
|
||||
return this.key;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString(){
|
||||
return this.key+" "+this.valeur+" "+this.ajouter;
|
||||
|
||||
String mot1 = "";
|
||||
String mot2 = "";
|
||||
if(this.ajouter) {
|
||||
|
||||
if(valeur < 0) {
|
||||
mot1 = "Retirer";
|
||||
}else {
|
||||
mot1 = "Ajouter";
|
||||
}
|
||||
|
||||
mot2 = " au ";
|
||||
|
||||
}else {
|
||||
mot1 = "Placer à";
|
||||
mot2 = " le ";
|
||||
}
|
||||
|
||||
return mot1+" "+valeur+" "+key+mot2+"joueur";
|
||||
}
|
||||
}
|
||||
|
@ -33,4 +33,9 @@ public class ActionAltererStatistiquesJoueurRoll extends ActionAltererStatistiqu
|
||||
|
||||
super.affecte(j1, j2);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString(){
|
||||
return "Lancer un dé "+valeurRoll+" pour modifier les "+this.getKey()+" du joueur";
|
||||
}
|
||||
}
|
||||
|
@ -18,5 +18,10 @@ public class ActionAttaquer extends Action {
|
||||
p.attaquer(j1, j2);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Attaquer un joueur";
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -8,10 +8,14 @@ public class ActionReveal extends Action {
|
||||
*
|
||||
*/
|
||||
private static final long serialVersionUID = 7972405763634156578L;
|
||||
|
||||
|
||||
@Override
|
||||
public void affecte(Joueur j1, Joueur j2) {
|
||||
j2.reveal();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Se réveler";
|
||||
}
|
||||
}
|
||||
|
@ -3,6 +3,7 @@ package effet.action;
|
||||
import java.util.List;
|
||||
|
||||
import carte.CarteEquipement;
|
||||
import javafx.scene.control.Label;
|
||||
import main.Joueur;
|
||||
|
||||
public class ActionVoler extends Action{
|
||||
@ -51,4 +52,10 @@ public class ActionVoler extends Action{
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "Voler un autre joueur";
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user