Android Open Source - LotR_Risk Region






From Project

Back to project page LotR_Risk.

License

The source code is released under:

GNU General Public License

If you think the Android project LotR_Risk listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package objects;
/* w w  w  .j a va  2s  .co m*/
import java.util.ArrayList;

public class Region {

  private String nom;
  private ArrayList<Territoire> tabTerritoire;
  private int nb_renforts; //Nombre de renforts lorsque rgion possd entirement
  
  public Region(String name, int nb_renf)
  {
    this.nom = name;
    this.nb_renforts = nb_renf;
    this.tabTerritoire = new ArrayList<Territoire>();
  }

  public void add_Territoire(Territoire t) {
    if (!this.tabTerritoire.contains(t))
      this.tabTerritoire.add(t);      
  }
  
  public Territoire get_Territoire(String nom) {
    for (Territoire t : this.tabTerritoire)
    {
      if (t.getNom().equals(nom))
        return t;
    }
    return null;
  }
  
  public int getNb_Territoires() {
    return this.tabTerritoire.size();
  }
  
  public String getNom() {
    return nom;
  }
  
  /* ONLY FOR TESTING */
  public void setNom(String s) {
    this.nom = s;
  }

  public int getNB_Renforts() {
    return nb_renforts;
  }
  
  public ArrayList<Territoire> getListTerritoire() {
    return tabTerritoire;
  }
}




Java Source Code List

com.activities.InitGameActivity.java
com.activities.StartUpActivity.java
com.custom.Compteur.java
com.custom.HelperCouleur.java
com.custom.Liste_Couleur.java
com.custom.ServiceReseau.java
com.game.InterfaceLOTR.java
com.game.LOTR_Data.java
com.net.DonneesConnexion.java
com.net.Emission.java
com.net.Reception.java
com.net.TacheConnexion.java
com.net.TacheTransmission.java
net.Emission.java
net.EnvoiReception.java
net.Reception.java
net.TestClient.java
net.ThreadConnexion.java
objects.Client.java
objects.Joueur.java
objects.Joueur.java
objects.Region.java
objects.Region.java
objects.Territoire.java
objects.Territoire.java
objects.TypeTerritoire.java
objects.TypeTerritoire.java
swingGUI.InfoJoueur.java
swingGUI.InfoTerritoire.java
swingGUI.Logger.java
swingGUI.MainWindow.java
swingGUI.Main.java
swingGUI.Map.java
utils.InterfaceLOTR.java
utils.LOTR_Data.java
utils.LOTR_Game.java
utils.Main.java