This commit is contained in:
Anuken 2020-12-12 18:49:24 -05:00
parent d171048004
commit d6546a38c0
4 changed files with 4 additions and 4 deletions

View file

@ -131,7 +131,7 @@ public class Damage{
}
//try to heal the tile
if(collide && hitter.type.collides(hitter, tile)){
if(collide && hitter.type.testCollision(hitter, tile)){
hitter.type.hitTile(hitter, tile, tile.health, false);
}
}

View file

@ -157,7 +157,7 @@ public abstract class BulletType extends Content{
return Math.max(speed * lifetime * (1f - drag), maxRange);
}
public boolean collides(Bullet bullet, Building tile){
public boolean testCollision(Bullet bullet, Building tile){
return healPercent <= 0.001f || tile.team != bullet.team || tile.healthf() < 1f;
}

View file

@ -125,7 +125,7 @@ abstract class BulletComp implements Timedc, Damagec, Hitboxc, Teamc, Posc, Draw
Building tile = world.build(x, y);
if(tile == null || !isAdded()) return false;
if(tile.collide(self()) && type.collides(self(), tile) && !tile.dead() && (type.collidesTeam || tile.team != team) && !(type.pierceBuilding && collided.contains(tile.id))){
if(tile.collide(self()) && type.testCollision(self(), tile) && !tile.dead() && (type.collidesTeam || tile.team != team) && !(type.pierceBuilding && collided.contains(tile.id))){
boolean remove = false;
float health = tile.health;

View file

@ -145,7 +145,7 @@ public class PlacementFragment extends Fragment{
break;
}
}
}else if(blockSelectEnd || Time.timeSinceMillis(blockSelectSeqMillis) > 750){ //1st number of combo, select category
}else if(blockSelectEnd || Time.timeSinceMillis(blockSelectSeqMillis) > 400){ //1st number of combo, select category
//select only visible categories
if(!getUnlockedByCategory(Category.all[i]).isEmpty()){
currentCategory = Category.all[i];