diff --git a/android/AndroidManifest.xml b/android/AndroidManifest.xml index 58f44d86e6..a14a86aa6f 100644 --- a/android/AndroidManifest.xml +++ b/android/AndroidManifest.xml @@ -1,8 +1,8 @@ + android:versionCode="7" + android:versionName="1.1.3" > @@ -14,7 +14,7 @@ diff --git a/android/res/drawable-hdpi/ic_launcher.png b/android/res/drawable-hdpi/ic_launcher.png index 209d92df9b..273651417a 100644 Binary files a/android/res/drawable-hdpi/ic_launcher.png and b/android/res/drawable-hdpi/ic_launcher.png differ diff --git a/android/res/drawable-mdpi/ic_launcher.png b/android/res/drawable-mdpi/ic_launcher.png index d190773fd1..c5039e6079 100644 Binary files a/android/res/drawable-mdpi/ic_launcher.png and b/android/res/drawable-mdpi/ic_launcher.png differ diff --git a/android/res/drawable-xhdpi/ic_launcher.png b/android/res/drawable-xhdpi/ic_launcher.png index a5996e0b18..7e2d2c0a8d 100644 Binary files a/android/res/drawable-xhdpi/ic_launcher.png and b/android/res/drawable-xhdpi/ic_launcher.png differ diff --git a/android/res/drawable-xxhdpi/ic_launcher.png b/android/res/drawable-xxhdpi/ic_launcher.png index 1a175ead89..052a0d02ac 100644 Binary files a/android/res/drawable-xxhdpi/ic_launcher.png and b/android/res/drawable-xxhdpi/ic_launcher.png differ diff --git a/android/res/drawable-xxxhdpi/ic_launcher.png b/android/res/drawable-xxxhdpi/ic_launcher.png index d1099464ab..7e5a96be63 100644 Binary files a/android/res/drawable-xxxhdpi/ic_launcher.png and b/android/res/drawable-xxxhdpi/ic_launcher.png differ diff --git a/build.gradle b/build.gradle index 6c2e9138cb..142d38bb71 100644 --- a/build.gradle +++ b/build.gradle @@ -79,8 +79,8 @@ project(":core") { apply plugin: "java" dependencies { - compile fileTree(dir: '../core/lib', include: '*.jar') - //compile 'com.github.anuken:ucore:1e7163626f' + //compile fileTree(dir: '../core/lib', include: '*.jar') + compile 'com.github.anuken:ucore:309fbe900d' compile "com.badlogicgames.gdx:gdx:$gdxVersion" compile "com.badlogicgames.gdx:gdx-ai:1.8.1" } diff --git a/core/assets/maps/test.png b/core/assets/maps/test.png index 2f49a602e1..aec9f3a5db 100644 Binary files a/core/assets/maps/test.png and b/core/assets/maps/test.png differ diff --git a/core/src/io/anuke/mindustry/Control.java b/core/src/io/anuke/mindustry/Control.java index c3ee486bfc..f0385b9471 100644 --- a/core/src/io/anuke/mindustry/Control.java +++ b/core/src/io/anuke/mindustry/Control.java @@ -131,7 +131,8 @@ public class Control extends RendererModule{ control.camera.position.set(player.x, player.y, 0); - wavetime = waveSpacing(); + //multiplying by 2 so you start with more time in the beginning + wavetime = waveSpacing()*2; if(showedTutorial || !Settings.getBool("tutorial")){ GameState.set(State.playing); @@ -393,7 +394,10 @@ public class Control extends RendererModule{ camera.position.set(lastx - deltax, lasty - deltay, 0); - record(); + if(Vars.debug){ + record(); + } + } if(!GameState.is(State.paused)){ diff --git a/core/src/io/anuke/mindustry/EffectLoader.java b/core/src/io/anuke/mindustry/EffectLoader.java index 22878e320b..f97e6a4220 100644 --- a/core/src/io/anuke/mindustry/EffectLoader.java +++ b/core/src/io/anuke/mindustry/EffectLoader.java @@ -9,6 +9,7 @@ import io.anuke.ucore.core.Effects; import io.anuke.ucore.graphics.Hue; public class EffectLoader{ + static Color lightRed = Hue.mix(Color.WHITE, Color.FIREBRICK, 0.1f); public static void create(){ @@ -25,6 +26,13 @@ public class EffectLoader{ Draw.reset(); }); + Effects.create("sparkbig", 11, e -> { + Draw.thickness(1f); + Draw.color(Hue.mix(lightRed, Color.GRAY, e.ifract())); + Draw.spikes(e.x, e.y, e.ifract() * 5f, 2.3f, 8); + Draw.reset(); + }); + Effects.create("smelt", 10, e -> { Draw.thickness(1f); Draw.color(Hue.mix(Color.YELLOW, Color.RED, e.ifract())); diff --git a/core/src/io/anuke/mindustry/Vars.java b/core/src/io/anuke/mindustry/Vars.java index 1a3fa8f008..28a3d94f0f 100644 --- a/core/src/io/anuke/mindustry/Vars.java +++ b/core/src/io/anuke/mindustry/Vars.java @@ -15,7 +15,7 @@ public class Vars{ //respawn time in frames public static final float respawnduration = 60*4; //time between waves in frames - public static final float wavespace = 20*60*(android ? 2 : 1); + public static final float wavespace = 30*60*(android ? 2 : 1); //how far away from spawn points the player can't place blocks public static final float enemyspawnspace = 65; //scale of the font diff --git a/core/src/io/anuke/mindustry/io/SaveIO.java b/core/src/io/anuke/mindustry/io/SaveIO.java index 5fbac076f4..bdc8218777 100644 --- a/core/src/io/anuke/mindustry/io/SaveIO.java +++ b/core/src/io/anuke/mindustry/io/SaveIO.java @@ -79,7 +79,7 @@ import io.anuke.ucore.entities.Entity; */ public class SaveIO{ /**Save file version ID. Should be incremented every breaking release.*/ - private static final int fileVersionID = 3; + private static final int fileVersionID = 4; private static FormatProvider provider = null; diff --git a/core/src/io/anuke/mindustry/resource/Item.java b/core/src/io/anuke/mindustry/resource/Item.java index b9c0f9e602..2824092bf3 100644 --- a/core/src/io/anuke/mindustry/resource/Item.java +++ b/core/src/io/anuke/mindustry/resource/Item.java @@ -1,5 +1,5 @@ package io.anuke.mindustry.resource; public enum Item{ - stone, iron, coal, steel; + stone, iron, coal, steel, titanium; } diff --git a/core/src/io/anuke/mindustry/world/blocks/Blocks.java b/core/src/io/anuke/mindustry/world/blocks/Blocks.java index 855ee87774..e6fe271654 100644 --- a/core/src/io/anuke/mindustry/world/blocks/Blocks.java +++ b/core/src/io/anuke/mindustry/world/blocks/Blocks.java @@ -23,14 +23,24 @@ public class Blocks{ solid = true; }}, - stone = new Block("stone"), + stone = new Block("stone"){{ + drops = new ItemStack(Item.stone, 1); + }}, + + iron = new Block("iron"){{ + drops = new ItemStack(Item.iron, 1); + }}, + + coal = new Block("coal"){{ + drops = new ItemStack(Item.coal, 1); + }}, + + titanium = new Block("titanium"){{ + drops = new ItemStack(Item.titanium, 1); + }}, dirt = new Block("dirt"), - iron = new Block("iron"), - - coal = new Block("coal"), - grass = new Block("grass"), stoneblock = new Block("stoneblock"){{ diff --git a/core/src/io/anuke/mindustry/world/blocks/Drill.java b/core/src/io/anuke/mindustry/world/blocks/Drill.java index 10e52532a8..d1f0ce4c46 100644 --- a/core/src/io/anuke/mindustry/world/blocks/Drill.java +++ b/core/src/io/anuke/mindustry/world/blocks/Drill.java @@ -52,12 +52,5 @@ public class Drill extends Block{ Draw.tscl(Vars.fontscale); } - - //@Override - public String error(Tile tile){ - if(tile.floor() != resource) - return "Not on iron ore block!"; - return null; - } } diff --git a/core/src/io/anuke/mindustry/world/blocks/ProductionBlocks.java b/core/src/io/anuke/mindustry/world/blocks/ProductionBlocks.java index e9229ca956..d18302d537 100644 --- a/core/src/io/anuke/mindustry/world/blocks/ProductionBlocks.java +++ b/core/src/io/anuke/mindustry/world/blocks/ProductionBlocks.java @@ -9,6 +9,7 @@ import io.anuke.mindustry.Vars; import io.anuke.mindustry.resource.Item; import io.anuke.mindustry.world.Block; import io.anuke.mindustry.world.Tile; +import io.anuke.ucore.core.Effects; import io.anuke.ucore.util.Timers; public class ProductionBlocks{ @@ -145,5 +146,34 @@ public class ProductionBlocks{ result = Item.coal; }}, - end = null; + titaniumdrill = new Drill("titaniumdrill"){{ + resource = Blocks.titanium; + result = Item.titanium; + }}, + + omnidrill = new Drill("omnidrill"){ + { + time = 4; + } + + @Override + public void update(Tile tile){ + + if(tile.floor().drops != null && Timers.get(tile, 60 * time)){ + offloadNear(tile, tile.floor().drops.item); + Effects.effect("sparkbig", tile.worldx(), tile.worldy()); + } + + if(Timers.get(tile.hashCode() + "dump", 30)){ + tryDump(tile); + } + } + + @Override + public String description(){ + return "Mines 1 of any resource every "+time+" seconds."; + } + } + + ; } diff --git a/core/src/io/anuke/mindustry/world/blocks/RepairTurret.java b/core/src/io/anuke/mindustry/world/blocks/RepairTurret.java index 45b5fd3d2c..11a8e6b28e 100644 --- a/core/src/io/anuke/mindustry/world/blocks/RepairTurret.java +++ b/core/src/io/anuke/mindustry/world/blocks/RepairTurret.java @@ -24,9 +24,9 @@ public class RepairTurret extends Turret{ if(entity.target != null){ float target = entity.angleTo(entity.target); - entity.rotation = Mathf.slerp(entity.rotation, target, 0.2f*Mathf.delta()); + entity.rotation = Mathf.slerp(entity.rotation, target, 0.16f*Mathf.delta()); - if(Timers.get(tile, reload) && Angles.angleDist(target, entity.rotation) < 12){ + if(Timers.get(tile, reload) && Angles.angleDist(target, entity.rotation) < 10){ entity.target.health++; } } diff --git a/desktop/gifexport/recording1503608273.gif b/desktop/gifexport/recording1503608273.gif new file mode 100644 index 0000000000..e3be820b92 Binary files /dev/null and b/desktop/gifexport/recording1503608273.gif differ diff --git a/desktop/gifexport/recording1503621654.gif b/desktop/gifexport/recording1503621654.gif new file mode 100644 index 0000000000..fc602c1f9e Binary files /dev/null and b/desktop/gifexport/recording1503621654.gif differ diff --git a/desktop/gifexport/recording1503621867.gif b/desktop/gifexport/recording1503621867.gif new file mode 100644 index 0000000000..cd82af4ee2 Binary files /dev/null and b/desktop/gifexport/recording1503621867.gif differ diff --git a/desktop/gifexport/recording1503696725.gif b/desktop/gifexport/recording1503696725.gif new file mode 100644 index 0000000000..ef516ac615 Binary files /dev/null and b/desktop/gifexport/recording1503696725.gif differ