mirror of
				https://github.com/Klagarge/PokeHES.git
				synced 2025-11-04 13:19:17 +00:00 
			
		
		
		
	Merge branch 'master' into dialog
This commit is contained in:
		@@ -7,24 +7,34 @@ import com.badlogic.gdx.math.Vector2;
 | 
			
		||||
import ch.hevs.gdx2d.lib.GdxGraphics;
 | 
			
		||||
 | 
			
		||||
public class Enemy extends Character{
 | 
			
		||||
    private String map;
 | 
			
		||||
 | 
			
		||||
    public TextEnemy textEnemy;
 | 
			
		||||
 | 
			
		||||
    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);
 | 
			
		||||
        //generate his text
 | 
			
		||||
        this.textEnemy = new TextEnemy(name);
 | 
			
		||||
        textEnemy.generateText();
 | 
			
		||||
        //TODO Auto-generated constructor stub
 | 
			
		||||
        this.map = map;
 | 
			
		||||
 | 
			
		||||
        turn(Character.Direction.DOWN);
 | 
			
		||||
        //generate the vector of fight
 | 
			
		||||
        fightData = new FightData(name);
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    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
 | 
			
		||||
@@ -32,11 +42,5 @@ public class Enemy extends Character{
 | 
			
		||||
        // TODO Auto-generated method stub
 | 
			
		||||
        
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
    public void draw(GdxGraphics arg0) {
 | 
			
		||||
        // TODO Auto-generated method stub
 | 
			
		||||
        
 | 
			
		||||
    }
 | 
			
		||||
    
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -36,7 +36,6 @@ public abstract class Entity implements DrawableObject {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void init(){
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void graphicRender(GdxGraphics g){
 | 
			
		||||
 
 | 
			
		||||
@@ -14,7 +14,7 @@ public class Player extends Character{
 | 
			
		||||
    private int xp;
 | 
			
		||||
 | 
			
		||||
    public Player(int x, int y) {
 | 
			
		||||
        super("Player", x, y, "lumberjack_sheet32");
 | 
			
		||||
        super("Player", x, y, "Character");
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    public void addXp(int xp){
 | 
			
		||||
@@ -46,7 +46,6 @@ public class Player extends Character{
 | 
			
		||||
 | 
			
		||||
			// Is the move valid ?
 | 
			
		||||
			if (sm.isWalkable(nextCell)) {
 | 
			
		||||
				// Go
 | 
			
		||||
				setSpeed(sm.getSpeed(nextCell));
 | 
			
		||||
				go(goalDirection);
 | 
			
		||||
			} else {
 | 
			
		||||
@@ -73,7 +72,15 @@ public class Player extends Character{
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
    public void move(int x, int y){
 | 
			
		||||
    private boolean enemy() {
 | 
			
		||||
		//Vector<Enemy> enemies = PokeMudry.getEnemies;
 | 
			
		||||
		//for (Enemy enemy : enemies) {
 | 
			
		||||
			
 | 
			
		||||
		//}
 | 
			
		||||
		return false;
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	public void move(int x, int y){
 | 
			
		||||
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user