many things

This commit is contained in:
Anuken
2020-09-17 21:05:16 -04:00
parent ce2dd89f44
commit ea224bd1f1
56 changed files with 6194 additions and 5682 deletions

View File

@@ -100,7 +100,7 @@ public class Wall extends Block{
//deflect bullets if necessary
if(deflect){
//slow bullets are not deflected
if(bullet.vel().len() <= 0.2f) return true;
if(bullet.vel().len() <= 0.2f || !bullet.type.reflectable) return true;
//bullet reflection chance depends on bullet damage
if(!Mathf.chance(chanceDeflect / bullet.damage())) return true;

View File

@@ -77,6 +77,7 @@ public abstract class Turret extends Block{
public Cons<TurretBuild> drawer = tile -> Draw.rect(region, tile.x + tr2.x, tile.y + tr2.y, tile.rotation - 90);
public Cons<TurretBuild> heatDrawer = tile -> {
if(tile.heat <= 0.00001f) return;
Draw.color(heatColor, tile.heat);
Draw.blend(Blending.additive);
Draw.rect(heatRegion, tile.x + tr2.x, tile.y + tr2.y, tile.rotation - 90);

View File

@@ -318,6 +318,12 @@ public class LogicBlock extends Block{
}
}
//logic blocks cause write problems when picked up
@Override
public boolean canPickup(){
return false;
}
@Override
public float range(){
return range;