From 95e663d1df40feac947e964c8f42579afaad3b23 Mon Sep 17 00:00:00 2001 From: Anuken Date: Sat, 5 Apr 2025 10:48:07 -0400 Subject: [PATCH] Misc bugfixes --- core/src/mindustry/content/UnitTypes.java | 8 +++++++- core/src/mindustry/entities/comp/TankComp.java | 2 +- .../mindustry/world/blocks/defense/RegenProjector.java | 3 ++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/core/src/mindustry/content/UnitTypes.java b/core/src/mindustry/content/UnitTypes.java index 6e3514620c..47d4cf92be 100644 --- a/core/src/mindustry/content/UnitTypes.java +++ b/core/src/mindustry/content/UnitTypes.java @@ -1017,6 +1017,7 @@ public class UnitTypes{ engineOffset = 7.8f; range = 140f; faceTarget = false; + autoDropBombs = true; armor = 3f; itemCapacity = 0; targetFlags = new BlockFlag[]{BlockFlag.factory, null}; @@ -1390,6 +1391,7 @@ public class UnitTypes{ drag = 0.017f; lowAltitude = false; flying = true; + autoDropBombs = true; circleTarget = true; engineOffset = 13f; engineSize = 7f; @@ -1908,6 +1910,7 @@ public class UnitTypes{ mixColorTo = Color.white; hitSound = Sounds.plasmaboom; + underwater = true; ejectEffect = Fx.none; hitSize = 22f; @@ -3280,6 +3283,7 @@ public class UnitTypes{ }}); weapons.add(new Weapon(){{ + shootSound = Sounds.none; shootCone = 360f; mirror = false; reload = 1f; @@ -3301,7 +3305,7 @@ public class UnitTypes{ tecta = new ErekirUnitType("tecta"){{ drag = 0.1f; speed = 0.6f; - hitSize = 23f; + hitSize = 30f; health = 7300; armor = 5f; @@ -3576,6 +3580,7 @@ public class UnitTypes{ elude = new ErekirUnitType("elude"){{ hovering = true; + canDrown = false; shadowElevation = 0.1f; drag = 0.07f; @@ -3862,6 +3867,7 @@ public class UnitTypes{ loopSoundVolume = 0.1f; weapons.add(new Weapon(){{ + shootSound = Sounds.none; shootCone = 360f; mirror = false; reload = 1f; diff --git a/core/src/mindustry/entities/comp/TankComp.java b/core/src/mindustry/entities/comp/TankComp.java index d1bc238263..056ad3374a 100644 --- a/core/src/mindustry/entities/comp/TankComp.java +++ b/core/src/mindustry/entities/comp/TankComp.java @@ -66,7 +66,7 @@ abstract class TankComp implements Posc, Hitboxc, Unitc, ElevationMovec{ solids ++; } - if(t.floor().isDeep()){ + if(t != null && t.floor().isDeep()){ lastDeepFloor = t.floor(); }else{ anyNonDeep = true; diff --git a/core/src/mindustry/world/blocks/defense/RegenProjector.java b/core/src/mindustry/world/blocks/defense/RegenProjector.java index f136560f38..15a163ff5c 100644 --- a/core/src/mindustry/world/blocks/defense/RegenProjector.java +++ b/core/src/mindustry/world/blocks/defense/RegenProjector.java @@ -134,6 +134,8 @@ public class RegenProjector extends Block{ return; } + anyTargets = targets.contains(b -> b.damaged()); + if(efficiency > 0){ if((optionalTimer += Time.delta * optionalEfficiency) >= optionalUseTime){ consume(); @@ -147,7 +149,6 @@ public class RegenProjector extends Block{ if(!build.damaged() || build.isHealSuppressed()) continue; didRegen = true; - anyTargets = true; int pos = build.pos(); //TODO periodic effect