This commit is contained in:
Simisays
2023-02-12 23:21:39 +01:00
parent db06e94ed6
commit 6a8f80d2c7
8 changed files with 16 additions and 7 deletions

View File

@@ -37,7 +37,6 @@ public class EnemySprite extends CharacterSprite {
public String nameOverride = ""; //Override name of this enemy in battles.
public RewardData[] rewards; //Additional rewards for this enemy.
public DialogData.ConditionData spawnCondition; //Condition to spawn.
public EnemySprite(EnemyData enemyData) {
this(0,enemyData);
}
@@ -49,7 +48,8 @@ public class EnemySprite extends CharacterSprite {
@Override
void updateBoundingRect() { //We want enemies to take the full tile.
boundingRect.set(getX(), getY(), getWidth(), getHeight());
float scale = this instanceof EnemySprite ? 2f :1f;
boundingRect.set(getX(), getY(), getWidth()*scale, getHeight()*scale);
}
public void moveTo(Actor other, float delta) {

View File

@@ -19,6 +19,7 @@ public class EnemyData {
public float spawnRate;
public float difficulty;
public float speed;
public float scale;
public int life;
public RewardData[] rewards;
public String[] equipment;
@@ -39,6 +40,7 @@ public class EnemyData {
copyPlayerDeck = enemyData.copyPlayerDeck;
difficulty = enemyData.difficulty;
speed = enemyData.speed;
scale = enemyData.scale;
life = enemyData.life;
equipment = enemyData.equipment;
colors = enemyData.colors;