This commit is contained in:
Anuken
2020-11-18 09:26:31 -05:00
parent adc7b30eab
commit f4a7288633
3 changed files with 11 additions and 10 deletions

View File

@@ -421,6 +421,7 @@ public class UnitTypes implements ContentList{
armor = 7f;
canBoost = true;
landShake = 4f;
immunities = ObjectSet.with(StatusEffects.burning);
commandLimit = 8;

View File

@@ -161,16 +161,16 @@ public abstract class BulletType extends Content{
return healPercent <= 0.001f || tile.team != bullet.team || tile.healthf() < 1f;
}
public void hitTile(Bullet b, Building tile, float initialHealth){
if(makeFire && tile.team != b.team){
Fires.create(tile.tile);
public void hitTile(Bullet b, Building build, float initialHealth){
if(makeFire && build.team != b.team){
Fires.create(build.tile);
}
if(healPercent > 0f && tile.team == b.team && !(tile.block instanceof ConstructBlock)){
Fx.healBlockFull.at(tile.x, tile.y, tile.block.size, Pal.heal);
tile.heal(healPercent / 100f * tile.maxHealth());
}else if(tile.team != b.team){
hit(b);
if(healPercent > 0f && build.team == b.team && !(build.block instanceof ConstructBlock)){
Fx.healBlockFull.at(build.x, build.y, build.block.size, Pal.heal);
build.heal(healPercent / 100f * build.maxHealth());
}else if(build.team != b.team){
hit(b, build.x, build.y);
}
}

View File

@@ -54,7 +54,7 @@ public class RailBulletType extends BulletType{
}
@Override
public void hitTile(Bullet b, Building tile, float initialHealth){
handle(b, tile, initialHealth);
public void hitTile(Bullet b, Building build, float initialHealth){
handle(b, build, initialHealth);
}
}