1
0
mirror of https://github.com/Klagarge/PokeHES.git synced 2025-10-30 19:29:17 +00:00
This commit is contained in:
2022-06-09 17:32:47 +02:00
parent 5573b545e0
commit 3d05c1e5fa
7 changed files with 115 additions and 133 deletions

View File

@@ -7,11 +7,13 @@ import com.badlogic.gdx.math.Vector2;
import ch.hevs.gdx2d.lib.GdxGraphics;
public class Enemy extends Character{
private String map;
public FightData fightData;
public Enemy(String name, int x, int y, String img) {
public Enemy(String name, int x, int y, String img, String map) {
super(name, x, y, img);
this.map = map;
turn(Character.Direction.DOWN);
//generate the vector of fight
@@ -20,12 +22,17 @@ public class Enemy extends Character{
}
public void setPosition(int x, int y){
public String getMap() {
return map;
}
public void setPosition(Vector2 vPosition){
setPosition((int)vPosition.x, (int)vPosition.y);
public void setPosition(int x, int y, String map){
position.set(x, y);
this.map = map;
}
public void setPosition(Vector2 vPosition, String map){
setPosition((int)vPosition.x, (int)vPosition.y, map);
}
@Override