diff --git a/JAVA/PROJET-PMT_STRI1A/.classpath b/JAVA/PROJET-PMT_STRI1A/.classpath deleted file mode 100644 index d54800d..0000000 --- a/JAVA/PROJET-PMT_STRI1A/.classpath +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - - - diff --git a/JAVA/PROJET-PMT_STRI1A/.gitignore b/JAVA/PROJET-PMT_STRI1A/.gitignore deleted file mode 100644 index ae3c172..0000000 --- a/JAVA/PROJET-PMT_STRI1A/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/bin/ diff --git a/JAVA/PROJET-PMT_STRI1A/.project b/JAVA/PROJET-PMT_STRI1A/.project deleted file mode 100644 index 1e5d08f..0000000 --- a/JAVA/PROJET-PMT_STRI1A/.project +++ /dev/null @@ -1,17 +0,0 @@ - - - PROJET-PMT_STRI1A - - - - - - org.eclipse.jdt.core.javabuilder - - - - - - org.eclipse.jdt.core.javanature - - diff --git a/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.core.prefs b/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.core.prefs deleted file mode 100644 index e256158..0000000 --- a/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.core.prefs +++ /dev/null @@ -1,12 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=11 -org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.compiler.compliance=11 -org.eclipse.jdt.core.compiler.debug.lineNumber=generate -org.eclipse.jdt.core.compiler.debug.localVariable=generate -org.eclipse.jdt.core.compiler.debug.sourceFile=generate -org.eclipse.jdt.core.compiler.problem.assertIdentifier=error -org.eclipse.jdt.core.compiler.problem.enumIdentifier=error -org.eclipse.jdt.core.compiler.release=enabled -org.eclipse.jdt.core.compiler.source=11 diff --git a/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.ui.prefs b/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.ui.prefs deleted file mode 100644 index a03bd4e..0000000 --- a/JAVA/PROJET-PMT_STRI1A/.settings/org.eclipse.jdt.ui.prefs +++ /dev/null @@ -1,3 +0,0 @@ -eclipse.preferences.version=1 -org.eclipse.jdt.ui.javadoc=true -org.eclipse.jdt.ui.text.custom_code_templates= diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Arme.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Arme.java deleted file mode 100644 index a6b4a53..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Arme.java +++ /dev/null @@ -1,41 +0,0 @@ -<<<<<<< HEAD - -package modeles; - -/** - * @author flavien - * - */ -public class Arme extends Objet { - - private int pArme; - -} -======= - -package modeles; - -/** - * @author flavien - * - */ -public class Arme extends Objet { - - private int pArme; - - public int getpArme() { - return this.pArme; - } - - public String getType() { - return "Arme"; - } - - public Arme(String nm, int valeur, int resistance, int attaque) { - super(nm, valeur, resistance); - this.pArme=attaque; - } - - /* public void effectArme ? (poison, incinération, gel, saignement, paralysie,... */ -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Armure.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Armure.java deleted file mode 100644 index a4560d6..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Armure.java +++ /dev/null @@ -1,46 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Armure extends Objet { - - private int pArmure; - -} -======= -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Armure extends Objet { - - private int pArmure; - - public int getpArmure() { - return this.pArmure; - } - - public String getType () { - return "Armure"; - } - - public Armure(String nm, int valeur, int resistance,int efficacité) { - super(nm, valeur, resistance); - this.pArmure=efficacité; - } - - - /* public armureEffect(...) */ -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Bourse.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Bourse.java deleted file mode 100644 index 946aa5c..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Bourse.java +++ /dev/null @@ -1,56 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Bourse extends Objet { - private int valeur; - -} -======= -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Bourse extends Objet { - private int valeur; - - public Bourse(int somme) { - super("bourse",somme,99999999); - - } - - public int getValeur() { - return this.valeur; - } - - public String getType() { - return "Bourse"; - } - - public int Achat(int cout) { //commande pour vérifier si la personne peut acheter un objet et pour faire le décompte de la thunasse - if (cout <= this.valeur) return (this.valeur=this.valeur-cout); - else { - int manque = cout-this.valeur; - System.out.println("L'achat est impossible, il vous manque : "+manque); - return manque; - } - } - - public int fusionBourse(Bourse sacPiece) { - this.valeur += sacPiece.valeur; - return this.valeur; - } - -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/EtreVivant.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/EtreVivant.java deleted file mode 100644 index e07fef5..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/EtreVivant.java +++ /dev/null @@ -1,141 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class EtreVivant { - private int pVieMax; - private int pVie; - private int pAttaque; - private Salle salle; - private boolean vivant; - -} -======= - -/** - * - */ -package modeles; - -/** - * @author Nicolas - * - */ -public class EtreVivant { - - private String nom; - protected int pVieMax; - protected int pVie; - private int pAttaque; - protected Salle salle; - private boolean vivant; - /** - * @param nom - * @param pVieMax - * @param pVie - * @param pAttaque - * @param salle - * @param vivant - */ - public EtreVivant(String nom, int pVieMax, int pAttaque, Salle salle) { - super(); - this.nom = nom; - this.pVieMax = pVieMax; - this.pVie = pVieMax; - this.pAttaque = pAttaque; - this.salle = salle; - this.vivant = true; - } - /** - * @return the nom - */ - public String getNom() { - return nom; - } - /** - * @param nom the nom to set - */ - public void setNom(String nom) { - this.nom = nom; - } - /** - * @return the pVieMax - */ - public int getpVieMax() { - return pVieMax; - } - /** - * @param pVieMax the pVieMax to set - */ - public void setpVieMax(int pVieMax) { - this.pVieMax = pVieMax; - } - /** - * @return the pVie - */ - public int getpVie() { - return pVie; - } - /** - * @param pVie the pVie to set - */ - public void setpVie(int pVie) { - this.pVie = pVie; - } - /** - * @return the pAttaque - */ - public int getpAttaque() { - return pAttaque; - } - /** - * @param pAttaque the pAttaque to set - */ - public void setpAttaque(int pAttaque) { - this.pAttaque = pAttaque; - } - /** - * @return the salle - */ - public Salle getSalle() { - return salle; - } - /** - * @param salle the salle to set - */ - public void setSalle(Salle salle) { - this.salle = salle; - } - /** - * @return the vivant - */ - public boolean isVivant() { - return vivant; - } - /** - * @param vivant the vivant to set - */ - public void setVivant(boolean vivant) { - this.vivant = vivant; - } - - public int getPvMax() { - return this.pVieMax; - } - - - - - - - - - -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Labyrinthe.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Labyrinthe.java deleted file mode 100644 index 544c663..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Labyrinthe.java +++ /dev/null @@ -1,23 +0,0 @@ -/** - * - */ -package modeles; - -import java.util.*; - -/** - * @author flavien - * - */ -public class Labyrinthe { - protected List listePersonnage=new ArrayList(); - protected ListlisteSalle= new ArrayList(); - protected List listeArme= new ArrayList(); - protected List listeArmure=new ArrayList(); - - public void generateLabyrinthe() { - } - - - -} diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Marche.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Marche.java deleted file mode 100644 index 256ba45..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Marche.java +++ /dev/null @@ -1,12 +0,0 @@ -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Marche extends Salle { - -} diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Monstre.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Monstre.java deleted file mode 100644 index 577e964..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Monstre.java +++ /dev/null @@ -1,24 +0,0 @@ -/** - * - */ -package modeles; - -/** - * @author Nicolas - * - */ -public class Monstre extends EtreVivant { - - /** - * @param arme - * @param armure - * @param bourse - */ - public Monstre(String nom, int pAttaque, Salle salle) { - super(nom, 5, pAttaque, salle); - - } - - - -} diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Objet.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Objet.java deleted file mode 100644 index 8a73ec7..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Objet.java +++ /dev/null @@ -1,68 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Objet { - private String nom; - private int prix; - private int usure; - -} -======= -package modeles; - -/** - * @author flavien - * - */ -public abstract class Objet { - private String nom; - private int prix; - private int usure; - private Personnage proprietaire; - - - public Objet(String nm, int valeur, int resistance) { - this.nom=nm; - this.prix=valeur; - this.usure=resistance; - } - - public int getPrix() { - return this.prix; - } - - public String getNom() { - return this.nom; - } - - public int getUsure() { - return this.usure; - } - - public void utilisation() { // diminue la résistance de l'objet - this.usure--; - if (this.usure == 0) System.out.println(this.nom+"s'est cassée !"); - } - - public abstract String getType(); - - public Personnage getProprietaire() { - return this.proprietaire; - } - - public void setProprietaire(Personnage perso) { - this.proprietaire=perso; - } - - public void lacher() { - this.proprietaire=null; - } -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Personnage.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Personnage.java deleted file mode 100644 index ed9fe14..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Personnage.java +++ /dev/null @@ -1,97 +0,0 @@ -<<<<<<< HEAD -package modeles; - -/** - * @author flavien - * - */ -public class Personnage extends EtreVivant { - public void equiper(Arme arme, Armure armure) { - - } - - public void utiliser(Potion potion) { - - } - public void seDeplacer() { - - } - public void allerMarche(Salle salle){ - - } - -} -======= -package modeles; - -/** - * @author Nicolas - * - */ -public class Personnage extends EtreVivant { - private Arme arme; - private Armure armure; - private Bourse bourse; - public Personnage(String nom, int pVieMax,int pAttaque, Salle salle) { - super(nom, pVieMax, pAttaque, salle); - } - - public void equiper(Arme arme) { - - arme.setProprietaire(this); - this.arme=arme; - } -public void equiper(Armure armure) { - armure.setProprietaire(this); - this.armure=armure; - } - - public void utiliser(Potion potion) { - soin(); - System.out.println("Pv au maximum"); - - } - public void seDeplacer(Salle salle) { - this.salle=salle; - } - public void allerMarche(Salle marche){ - this.salle=marche; - } - public void soin() { - this.pVie=this.pVieMax; - } - public void attaquer(Monstre monstre) { - if(arme!=null) { - monstre.pVie=monstre.pVie-(arme.getpArme()+getpAttaque()); - } - else { - monstre.pVie=monstre.pVie=getpAttaque(); - } -} - public Bourse getBourse() { - return this.bourse; - } - - public void getValeurBourse() { - System.out.println(this.getBourse().getValeur()); - } - /** - * @return the arme - */ - public Arme getArme() { - return arme; - } - - /** - * @return the armure - */ - public Armure getArmure() { - return armure; - } - - public void soin(int heal) { - if (pVie+heal > pVieMax)pVie=pVieMax; - else pVie+=heal; - } -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Porte.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Porte.java deleted file mode 100644 index 61f866d..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Porte.java +++ /dev/null @@ -1,47 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Porte { - private boolean ouvert; - private char orientation; - - public boolean estOuverte() { - return ouvert; - } - - public char getOrientation() { - return orientation; - } - -} -======= -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Porte { - private boolean ouvert; - private char orientation; - - public boolean estOuverte() { - return ouvert; - } - - public char getOrientation() { - return orientation; - } - -} ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Potion.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Potion.java deleted file mode 100644 index 5e57481..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Potion.java +++ /dev/null @@ -1,25 +0,0 @@ -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Potion extends Objet { - public String getType() { - return "Potion"; - } - - public Potion(int valeur) { - super("potion", valeur, 1); - } - - public void utilisation() { - super.utilisation(); - this.getProprietaire().soin(this.getProprietaire().getpVieMax()); - } - - -} diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/Salle.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/Salle.java deleted file mode 100644 index 377e31c..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/Salle.java +++ /dev/null @@ -1,61 +0,0 @@ -<<<<<<< HEAD -/** - * - */ -package modeles; - -/** - * @author flavien - * - */ -public class Salle { - private int positionX; - private int positionY; - private boolean sortie; - - public String getType(){ - return"type"; - } - -} -======= -/** - * - */ -package modeles; - -import java.util.ArrayList; -import java.util.List; - -/** - * @author flavien - * - */ -public class Salle { - private int positionX; - private int positionY; - private boolean sortie; - private List listeEnnemie= new ArrayList(); - - public String getType(){ - return "salle"; - } - - public int getPositionX() { - return this.positionX; - } - - public int getPositionY() { - return this.positionY; - } - - public boolean estSortie() { - return sortie; - } - - public boolean estVide() { - return listeEnnemie.isEmpty(); - } -} - ->>>>>>> theo diff --git a/JAVA/PROJET-PMT_STRI1A/src/modeles/sauvegarde.java b/JAVA/PROJET-PMT_STRI1A/src/modeles/sauvegarde.java deleted file mode 100644 index 4e3b248..0000000 --- a/JAVA/PROJET-PMT_STRI1A/src/modeles/sauvegarde.java +++ /dev/null @@ -1,42 +0,0 @@ -package modeles; - -import java.io.File; -import java.io.FileWriter; -import java.io.IOException; - - -public class sauvegarde { - - public void enregistrerPersonnage(Labyrinthe lab) { - try { - File f= new File("./personnage.json"); - f.createNewFile(); - FileWriter fw= new FileWriter(f,true); - for (int i =0; i