1
0
mirror of https://github.com/Klagarge/PokeHES.git synced 2025-03-14 14:54:33 +00:00
PokeHES/src/Game/Battle.java
Fastium 6248936e5a d
2022-06-12 14:26:02 +02:00

49 lines
829 B
Java

package Game;
import Entity.Enemy;
import Text.TextEnemy;
public class Battle {
private Enemy enemy;
TextEnemy textEnemy;
private int lineSpeech;
public int answer;
public Battle(Enemy enemy){
this.enemy = enemy;
textEnemy = new TextEnemy("enemi"); // should be enemy.name
textEnemy.generateText();
lineSpeech = 0;
answer = 0;
//initialize the first line
System.out.println("lll : "+ getLine());
}
public void readNextLine(){
//change line
lineSpeech++;
}
public boolean getAttackOn(){
return textEnemy.lines.get(lineSpeech).attackOn;
}
public String getLine(){
return textEnemy.lines.get(lineSpeech).line;
}
public int getLineSpeech() {
return lineSpeech;
}
}