diff --git a/core/src/io/anuke/mindustry/content/blocks/PowerBlocks.java b/core/src/io/anuke/mindustry/content/blocks/PowerBlocks.java index aa643f51a7..f5eddd6dee 100644 --- a/core/src/io/anuke/mindustry/content/blocks/PowerBlocks.java +++ b/core/src/io/anuke/mindustry/content/blocks/PowerBlocks.java @@ -73,12 +73,13 @@ public class PowerBlocks extends BlockList implements ContentList{ powerNode = new PowerNode("power-node"){{ shadow = "shadow-round-1"; + powerSpeed = 0.5f; maxNodes = 4; }}; powerNodeLarge = new PowerNode("power-node-large"){{ size = 2; - powerSpeed = 1f; + powerSpeed = 1.5f; maxNodes = 6; laserRange = 7.5f; shadow = "shadow-round-2"; diff --git a/core/src/io/anuke/mindustry/core/NetClient.java b/core/src/io/anuke/mindustry/core/NetClient.java index ef139eb9c9..6d880215f4 100644 --- a/core/src/io/anuke/mindustry/core/NetClient.java +++ b/core/src/io/anuke/mindustry/core/NetClient.java @@ -217,7 +217,7 @@ public class NetClient extends Module{ int totalChunks = Mathf.ceil((float) totalLength / NetServer.maxSnapshotSize); //reset status when a new snapshot sending begins - if(netClient.currentSnapshotID != snapshotID || netClient.recievedChunks == null){ + if(netClient.currentSnapshotID != snapshotID || netClient.recievedChunks == null || netClient.recievedChunks.length != totalChunks){ netClient.currentSnapshotID = snapshotID; netClient.currentSnapshot = new byte[totalLength]; netClient.recievedChunkCounter = 0; diff --git a/core/src/io/anuke/mindustry/entities/TileEntity.java b/core/src/io/anuke/mindustry/entities/TileEntity.java index c663bda16d..afada0b3fc 100644 --- a/core/src/io/anuke/mindustry/entities/TileEntity.java +++ b/core/src/io/anuke/mindustry/entities/TileEntity.java @@ -127,6 +127,10 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{ tile.block().handleBulletHit(this, other); } + public void kill(){ + Call.onTileDestroyed(tile); + } + public void damage(float damage){ if(dead) return; diff --git a/core/src/io/anuke/mindustry/world/blocks/power/NuclearReactor.java b/core/src/io/anuke/mindustry/world/blocks/power/NuclearReactor.java index 9759b2e63e..a4a6894cdf 100644 --- a/core/src/io/anuke/mindustry/world/blocks/power/NuclearReactor.java +++ b/core/src/io/anuke/mindustry/world/blocks/power/NuclearReactor.java @@ -121,8 +121,8 @@ public class NuclearReactor extends PowerGenerator{ entity.heat = Mathf.clamp(entity.heat); - if(entity.heat >= 1f){ - entity.damage((int) entity.health); + if(entity.heat >= 0.999f){ + entity.kill(); }else{ distributePower(tile); } @@ -141,9 +141,7 @@ public class NuclearReactor extends PowerGenerator{ Effects.shake(6f, 16f, tile.worldx(), tile.worldy()); Effects.effect(ExplosionFx.nuclearShockwave, tile.worldx(), tile.worldy()); for(int i = 0; i < 6; i++){ - Timers.run(Mathf.random(40), () -> { - Effects.effect(BlockFx.nuclearcloud, tile.worldx(), tile.worldy()); - }); + Timers.run(Mathf.random(40), () -> Effects.effect(BlockFx.nuclearcloud, tile.worldx(), tile.worldy())); } Damage.damage(tile.worldx(), tile.worldy(), explosionRadius * tilesize, explosionDamage * 4);