forked from fiuba/algo3_proyecto_base_tp2
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: primeras implementaciones de Juego.
Co-authored-by: mariagalindez <mgalindez@fi.uba.ar> Co-authored-by: Sebakrag <sebaskrag@gmail.com>
- Loading branch information
1 parent
d74e856
commit ed2c888
Showing
4 changed files
with
63 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,48 @@ | ||
package edu.fiuba.algo3.modelo; | ||
|
||
import edu.fiuba.algo3.modelo.celdas.CeldaInicial; | ||
|
||
import java.util.*; | ||
|
||
|
||
public class Juego { | ||
private Tablero tablero; | ||
private int cantidadJugadores; // Lo borramos? Podemos pedirlo por interfaz grafica. | ||
private ArrayList<Jugador> jugadores; | ||
|
||
public Juego() { | ||
// Instanciar la interfaz grafica --> se pide la cantidad de jugadores y el ingreso de los nombres.?????? | ||
// VERIFICAR QUE LOS JUGADORES INGRESADOS SEN ENTRE 2 Y 6 | ||
this.jugadores = new ArrayList<Jugador>(); | ||
|
||
CeldaInicial celdaInicial = new CeldaInicial(); | ||
this.tablero = new Tablero(celdaInicial); | ||
} | ||
|
||
public void iniciarJuego(int cantidadCeldas){ | ||
this.tablero.armarMapa(cantidadCeldas); | ||
|
||
//Cantidad de jugadores a jugar -> Lo pedimos por interfaz. | ||
this.crearJugadores(this.cantidadJugadores); | ||
|
||
|
||
} | ||
|
||
public void crearJugadores(int cantidadJugadores) { | ||
for (int i = 0; i < cantidadJugadores; i++) { | ||
Gladiador gladiador = new Gladiador(); | ||
//Jugador jugador = new Jugador(gladiador, this.tablero.getCeldaInicial()); | ||
//this.jugadores.add(jugador); | ||
} | ||
} | ||
|
||
// Este metodo va aca (no en Jugador): | ||
// public boolean chequearTurno(){ | ||
// if (this.turnos != 30) { | ||
// this.turnos ++; | ||
// return true; | ||
// } else { | ||
// return false; | ||
// } | ||
// } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters