diff --git a/core/src/mindustry/Vars.java b/core/src/mindustry/Vars.java index 0e321e1ed6..21a8b3fb45 100644 --- a/core/src/mindustry/Vars.java +++ b/core/src/mindustry/Vars.java @@ -88,7 +88,7 @@ public class Vars implements Loadable{ /** duration of time between turns in ticks */ public static final float turnDuration = 2 * Time.toMinutes; /** chance of an invasion per turn, 1 = 100% */ - public static final float baseInvasionChance = 1f / 60f; + public static final float baseInvasionChance = 1f / 75f; /** how many turns have to pass before invasions start */ public static final int invasionGracePeriod = 20; /** min armor fraction damage; e.g. 0.05 = at least 5% damage */ diff --git a/core/src/mindustry/content/Blocks.java b/core/src/mindustry/content/Blocks.java index 02d3820bc4..98c835f026 100644 --- a/core/src/mindustry/content/Blocks.java +++ b/core/src/mindustry/content/Blocks.java @@ -1195,7 +1195,7 @@ public class Blocks implements ContentList{ size = 2; ambientSound = Sounds.smelter; - ambientSoundVolume = 0.05f; + ambientSoundVolume = 0.06f; }}; differentialGenerator = new SingleTypeGenerator("differential-generator"){{ diff --git a/core/src/mindustry/entities/bullet/SapBulletType.java b/core/src/mindustry/entities/bullet/SapBulletType.java index 9d05a37e9a..dbd30b77a8 100644 --- a/core/src/mindustry/entities/bullet/SapBulletType.java +++ b/core/src/mindustry/entities/bullet/SapBulletType.java @@ -61,7 +61,7 @@ public class SapBulletType extends BulletType{ b.data = target; if(target != null){ - float result = Math.min(target.health(), damage); + float result = Math.max(Math.min(target.health(), damage), 0); if(b.owner instanceof Healthc h){ h.heal(result * sapStrength); diff --git a/core/src/mindustry/game/Schematics.java b/core/src/mindustry/game/Schematics.java index 7cd51ecec4..2d526606c7 100644 --- a/core/src/mindustry/game/Schematics.java +++ b/core/src/mindustry/game/Schematics.java @@ -127,6 +127,9 @@ public class Schematics implements Loadable{ newSchematic.tags.putAll(target.tags); newSchematic.file = target.file; + loadouts.each((block, list) -> list.remove(target)); + checkLoadout(target, true); + try{ write(newSchematic, target.file); }catch(Exception e){ @@ -134,6 +137,8 @@ public class Schematics implements Loadable{ Log.err(e); ui.showException(e); } + + } private @Nullable Schematic loadFile(Fi file){ diff --git a/core/src/mindustry/game/Waves.java b/core/src/mindustry/game/Waves.java index 28f742a3cd..5958d5f22f 100644 --- a/core/src/mindustry/game/Waves.java +++ b/core/src/mindustry/game/Waves.java @@ -10,7 +10,7 @@ import mindustry.type.*; import static mindustry.content.UnitTypes.*; public class Waves{ - public static final int waveVersion = 3; + public static final int waveVersion = 4; private Seq spawns; @@ -277,7 +277,7 @@ public class Waves{ int cap = 150; float shieldStart = 30, shieldsPerWave = 20 + difficulty*30f; - float[] scaling = {1, 1.2f, 2f, 3f, 4f}; + float[] scaling = {1, 1.5f, 3f, 4f, 5f}; Intc createProgression = start -> { //main sequence @@ -286,7 +286,7 @@ public class Waves{ for(int i = start; i < cap;){ int f = i; - int next = rand.random(8, 16) + (int)Mathf.lerp(4f, 0f, difficulty) + curTier * 4; + int next = rand.random(8, 16) + (int)Mathf.lerp(5f, 0f, difficulty) + curTier * 4; float shieldAmount = Math.max((i - shieldStart) * shieldsPerWave, 0); int space = start == 0 ? 1 : rand.random(1, 2); @@ -298,7 +298,7 @@ public class Waves{ begin = f; end = f + next >= cap ? never : f + next; max = 13; - unitScaling = (difficulty < 0.4f ? rand.random(2.5f, 4f) : rand.random(1f, 4f)) * scaling[ctier]; + unitScaling = (difficulty < 0.4f ? rand.random(2.5f, 5f) : rand.random(1f, 4f)) * scaling[ctier]; shields = shieldAmount; shieldScaling = shieldsPerWave; spacing = space; diff --git a/core/src/mindustry/maps/SectorDamage.java b/core/src/mindustry/maps/SectorDamage.java index 045a0bd75b..a86bc47356 100644 --- a/core/src/mindustry/maps/SectorDamage.java +++ b/core/src/mindustry/maps/SectorDamage.java @@ -437,7 +437,7 @@ public class SectorDamage{ float falloff = (fraction) / (Math.max(tiles.width, tiles.height) * Mathf.sqrt2); int peak = 0; - if(fraction > 0.1f){ + if(fraction > 0.15f){ //phase two: propagate the damage while(!frontier.isEmpty()){ peak = Math.max(peak, frontier.size); diff --git a/core/src/mindustry/ui/dialogs/PlanetDialog.java b/core/src/mindustry/ui/dialogs/PlanetDialog.java index a7d0c837de..4700bc0906 100644 --- a/core/src/mindustry/ui/dialogs/PlanetDialog.java +++ b/core/src/mindustry/ui/dialogs/PlanetDialog.java @@ -167,6 +167,7 @@ public class PlanetDialog extends BaseDialog implements PlanetInterfaceRenderer{ } newPresets.reverse(); + updateSelected(); if(planets.planet.getLastSector() != null){ lookAt(planets.planet.getLastSector());