mirror of
https://github.com/Anuken/Mindustry.git
synced 2026-09-22 04:58:39 +03:00
Fixed sap bullets being able to pierce shields + placeholder balance adjustment for Eclipse lasers
This commit is contained in:
@@ -1308,6 +1308,7 @@ public class UnitTypes{
|
||||
sideLength = 80f;
|
||||
width = 25f;
|
||||
length = 230f;
|
||||
shieldDamageMultiplier = 2f;
|
||||
shootEffect = Fx.shockwave;
|
||||
colors = new Color[]{Color.valueOf("ec7458aa"), Color.valueOf("ff9c5a"), Color.white};
|
||||
}};
|
||||
|
||||
@@ -66,7 +66,7 @@ public class BulletType extends Content implements Cloneable{
|
||||
/** For piercing lasers, setting this to true makes it get absorbed by plastanium walls. */
|
||||
public boolean laserAbsorb = true;
|
||||
/** Whether force shields absorb this bullet when it hits as a line, even if it isn't a laser. Used by rails. */
|
||||
public boolean shieldAbsorb = false;
|
||||
public boolean shieldAbsorb = true;
|
||||
/** Whether this bullet is considered a laser bullet and thus absorbed by plastanium walls. */
|
||||
public boolean laserBullet = false;
|
||||
/** Life fraction at which this bullet has the best range/damage/etc. Used for lasers and continuous turrets. */
|
||||
|
||||
@@ -102,7 +102,7 @@ public class PointLaserBulletType extends BulletType{
|
||||
|
||||
@Override
|
||||
public float shieldDamage(Bullet b){
|
||||
return b.damage / damageInterval * Time.delta;
|
||||
return b.damage / damageInterval * Time.delta * shieldDamageMultiplier;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -42,6 +42,7 @@ public class SapBulletType extends BulletType{
|
||||
lightOpacity = 0.6f;
|
||||
statusDuration = 60f * 3f;
|
||||
impact = true;
|
||||
shieldAbsorb = true;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -74,8 +75,10 @@ public class SapBulletType extends BulletType{
|
||||
super.init(b);
|
||||
|
||||
float len = Mathf.random(length, length + lengthRand);
|
||||
len = Math.min(len, Damage.findShieldLength(b, len, false, true));
|
||||
|
||||
Healthc target = Damage.linecast(b, b.x, b.y, b.rotation(), len);
|
||||
|
||||
b.data = target;
|
||||
|
||||
if(target != null){
|
||||
|
||||
Reference in New Issue
Block a user