diff --git a/core/assets-raw/sprites/blocks/production/plasmadrill-rim.png b/core/assets-raw/sprites/blocks/production/plasmadrill-rim.png index aea5ee0b3b..f828a5924b 100644 Binary files a/core/assets-raw/sprites/blocks/production/plasmadrill-rim.png and b/core/assets-raw/sprites/blocks/production/plasmadrill-rim.png differ diff --git a/core/assets-raw/sprites/blocks/production/plasmadrill.png b/core/assets-raw/sprites/blocks/production/plasmadrill.png index bb9ff3c6af..30a8a86d99 100644 Binary files a/core/assets-raw/sprites/blocks/production/plasmadrill.png and b/core/assets-raw/sprites/blocks/production/plasmadrill.png differ diff --git a/core/assets/sprites/sprites.png b/core/assets/sprites/sprites.png index 03a6e53e84..f6d446a635 100644 Binary files a/core/assets/sprites/sprites.png and b/core/assets/sprites/sprites.png differ diff --git a/core/assets/version.properties b/core/assets/version.properties index a7067572ca..c891d54e54 100644 --- a/core/assets/version.properties +++ b/core/assets/version.properties @@ -1,7 +1,7 @@ #Autogenerated file. Do not modify. -#Sat Mar 31 22:48:10 EDT 2018 +#Sun Apr 01 10:41:23 EDT 2018 version=release -androidBuildCode=805 +androidBuildCode=807 name=Mindustry code=3.4 build=custom build diff --git a/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java b/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java index 657adb52d2..25d80a46e3 100644 --- a/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java +++ b/core/src/io/anuke/mindustry/content/blocks/WeaponBlocks.java @@ -26,6 +26,7 @@ public class WeaponBlocks{ bullet = BulletType.stone; ammo = Items.stone; health = 45; + shots = 2; } @Override diff --git a/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java b/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java index ef98075c4c..23076b8eaf 100644 --- a/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java +++ b/core/src/io/anuke/mindustry/world/blocks/types/defense/Turret.java @@ -34,6 +34,7 @@ public class Turret extends Block{ protected float reload = 10f; protected float inaccuracy = 0f; protected int shots = 1; + protected float shotTransation = 2; protected float shotDelayScale = 0; protected String shootsound = "shoot"; protected BulletType bullet = BulletType.iron; @@ -42,7 +43,7 @@ public class Turret extends Block{ protected int maxammo = 400; protected float rotatespeed = 0.2f; protected float shootCone = 5f; - protected Effect shootEffect = null; + protected Effect shootEffect = Fx.none; protected float shootShake = 0f; protected int soundReload = 0; protected Translator tr = new Translator(); @@ -168,11 +169,6 @@ public class Turret extends Block{ entity.ammo --; } - @Override - public TileEntity getEntity(){ - return new TurretEntity(); - } - void drawTargeting(Tile tile){ TurretEntity entity = tile.entity(); @@ -201,9 +197,7 @@ public class Turret extends Block{ Draw.reset(); if(Timers.getTime(tile, "reload") <= 0){ - Timers.run(hittime, ()->{ - Effects.effect(Fx.spawn, predictX, predictY); - }); + Timers.run(hittime, () -> Effects.effect(Fx.spawn, predictX, predictY)); } } @@ -214,6 +208,7 @@ public class Turret extends Block{ for(int i = 0; i < shots; i ++){ if(Mathf.zero(shotDelayScale)){ + bullet(tile, entity.rotation + Mathf.range(inaccuracy)); }else{ Timers.run(i * shotDelayScale, () -> { @@ -223,11 +218,9 @@ public class Turret extends Block{ } } - - if(shootEffect != null){ - Effects.effect(shootEffect, tile.drawx() + tr.x, - tile.drawy() + tr.y, entity.rotation); - } + + Effects.effect(shootEffect, tile.drawx() + tr.x, + tile.drawy() + tr.y, entity.rotation); if(shootShake > 0){ Effects.shake(shootShake, shootShake, tile.entity); @@ -237,6 +230,11 @@ public class Turret extends Block{ protected void bullet(Tile tile, float angle){ new Bullet(bullet, tile.entity, tile.getTeam(), tile.drawx() + tr.x, tile.drawy() + tr.y, angle).add(); } + + @Override + public TileEntity getEntity(){ + return new TurretEntity(); + } public static class TurretEntity extends TileEntity{ public TileEntity blockTarget; diff --git a/core/src/io/anuke/mindustry/world/blocks/types/power/FusionReactor.java b/core/src/io/anuke/mindustry/world/blocks/types/power/FusionReactor.java index 11e335ddd7..9e71978c1a 100644 --- a/core/src/io/anuke/mindustry/world/blocks/types/power/FusionReactor.java +++ b/core/src/io/anuke/mindustry/world/blocks/types/power/FusionReactor.java @@ -47,6 +47,8 @@ public class FusionReactor extends PowerGenerator { float powerAdded = Math.min(powerCapacity - entity.power.amount, maxPowerProduced * Mathf.pow(entity.warmup, 3f) * Timers.delta()); entity.power.amount += powerAdded; entity.totalProgress += entity.warmup * Timers.delta(); + + distributePower(tile); } @Override