mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-02-19 03:03:59 +07:00
Bugfixes
This commit is contained in:
parent
8162e13f04
commit
8359789d4f
Binary file not shown.
@ -1613,13 +1613,13 @@ public class Blocks implements ContentList{
|
|||||||
}};
|
}};
|
||||||
|
|
||||||
spiritFactory = new UnitFactory("spirit-factory"){{
|
spiritFactory = new UnitFactory("spirit-factory"){{
|
||||||
requirements(Category.units, ItemStack.with(Items.metaglass, 35, Items.lead, 55, Items.silicon, 45));
|
requirements(Category.units, ItemStack.with(Items.metaglass, 45, Items.lead, 55, Items.silicon, 45));
|
||||||
type = UnitTypes.spirit;
|
type = UnitTypes.spirit;
|
||||||
produceTime = 2850;
|
produceTime = 3500;
|
||||||
size = 2;
|
size = 2;
|
||||||
maxSpawn = 2;
|
maxSpawn = 2;
|
||||||
consumes.power(0.80f);
|
consumes.power(0.80f);
|
||||||
consumes.items(new ItemStack(Items.silicon, 10), new ItemStack(Items.lead, 15));
|
consumes.items(new ItemStack(Items.silicon, 15), new ItemStack(Items.lead, 15));
|
||||||
}};
|
}};
|
||||||
|
|
||||||
phantomFactory = new UnitFactory("phantom-factory"){{
|
phantomFactory = new UnitFactory("phantom-factory"){{
|
||||||
|
@ -1,19 +1,16 @@
|
|||||||
package io.anuke.mindustry.content;
|
package io.anuke.mindustry.content;
|
||||||
|
|
||||||
import io.anuke.arc.graphics.Color;
|
import io.anuke.arc.graphics.*;
|
||||||
import io.anuke.arc.graphics.g2d.*;
|
import io.anuke.arc.graphics.g2d.*;
|
||||||
import io.anuke.arc.math.Mathf;
|
import io.anuke.arc.math.*;
|
||||||
import io.anuke.arc.util.Time;
|
import io.anuke.arc.util.*;
|
||||||
import io.anuke.arc.util.Tmp;
|
import io.anuke.mindustry.entities.*;
|
||||||
import io.anuke.mindustry.entities.Damage;
|
|
||||||
import io.anuke.mindustry.entities.Effects;
|
|
||||||
import io.anuke.mindustry.entities.bullet.*;
|
import io.anuke.mindustry.entities.bullet.*;
|
||||||
import io.anuke.mindustry.entities.effect.*;
|
import io.anuke.mindustry.entities.effect.*;
|
||||||
import io.anuke.mindustry.entities.type.Unit;
|
import io.anuke.mindustry.game.*;
|
||||||
import io.anuke.mindustry.game.ContentList;
|
import io.anuke.mindustry.graphics.*;
|
||||||
import io.anuke.mindustry.graphics.Pal;
|
import io.anuke.mindustry.world.*;
|
||||||
import io.anuke.mindustry.world.Tile;
|
import io.anuke.mindustry.world.blocks.*;
|
||||||
import io.anuke.mindustry.world.blocks.BuildBlock;
|
|
||||||
|
|
||||||
import static io.anuke.mindustry.Vars.world;
|
import static io.anuke.mindustry.Vars.world;
|
||||||
|
|
||||||
@ -43,7 +40,7 @@ public class Bullets implements ContentList{
|
|||||||
fireball, basicFlame, pyraFlame, driverBolt, healBullet, frag, eruptorShot,
|
fireball, basicFlame, pyraFlame, driverBolt, healBullet, frag, eruptorShot,
|
||||||
|
|
||||||
//bombs
|
//bombs
|
||||||
bombExplosive, bombIncendiary, bombOil, explode;
|
bombExplosive, bombIncendiary, bombOil;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void load(){
|
public void load(){
|
||||||
@ -703,23 +700,5 @@ public class Bullets implements ContentList{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
explode = new BombBulletType(2f, 3f, "clear"){
|
|
||||||
{
|
|
||||||
hitEffect = Fx.pulverize;
|
|
||||||
lifetime = 30f;
|
|
||||||
speed = 1f;
|
|
||||||
splashDamageRadius = 50f;
|
|
||||||
splashDamage = 28f;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void init(Bullet b){
|
|
||||||
if(b.getOwner() instanceof Unit){
|
|
||||||
((Unit)b.getOwner()).kill();
|
|
||||||
}
|
|
||||||
b.time(b.lifetime());
|
|
||||||
}
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,10 +1,11 @@
|
|||||||
package io.anuke.mindustry.content;
|
package io.anuke.mindustry.content;
|
||||||
|
|
||||||
import io.anuke.arc.collection.ObjectSet;
|
import io.anuke.arc.collection.*;
|
||||||
|
import io.anuke.mindustry.entities.bullet.*;
|
||||||
|
import io.anuke.mindustry.entities.type.*;
|
||||||
import io.anuke.mindustry.entities.type.base.*;
|
import io.anuke.mindustry.entities.type.base.*;
|
||||||
import io.anuke.mindustry.game.ContentList;
|
import io.anuke.mindustry.game.*;
|
||||||
import io.anuke.mindustry.type.UnitType;
|
import io.anuke.mindustry.type.*;
|
||||||
import io.anuke.mindustry.type.Weapon;
|
|
||||||
|
|
||||||
public class UnitTypes implements ContentList{
|
public class UnitTypes implements ContentList{
|
||||||
public static UnitType
|
public static UnitType
|
||||||
@ -90,16 +91,32 @@ public class UnitTypes implements ContentList{
|
|||||||
}};
|
}};
|
||||||
|
|
||||||
crawler = new UnitType("crawler", Crawler.class, Crawler::new){{
|
crawler = new UnitType("crawler", Crawler.class, Crawler::new){{
|
||||||
maxVelocity = 1.25f;
|
maxVelocity = 1.27f;
|
||||||
speed = 0.28f;
|
speed = 0.285f;
|
||||||
drag = 0.4f;
|
drag = 0.4f;
|
||||||
hitsize = 8f;
|
hitsize = 8f;
|
||||||
mass = 1.75f;
|
mass = 1.75f;
|
||||||
health = 100;
|
health = 120;
|
||||||
weapon = new Weapon("bomber"){{
|
weapon = new Weapon("bomber"){{
|
||||||
reload = 12f;
|
reload = 12f;
|
||||||
ejectEffect = Fx.none;
|
ejectEffect = Fx.none;
|
||||||
bullet = Bullets.explode;
|
bullet = new BombBulletType(2f, 3f, "clear"){
|
||||||
|
{
|
||||||
|
hitEffect = Fx.pulverize;
|
||||||
|
lifetime = 30f;
|
||||||
|
speed = 1.1f;
|
||||||
|
splashDamageRadius = 55f;
|
||||||
|
splashDamage = 30f;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void init(Bullet b){
|
||||||
|
if(b.getOwner() instanceof Unit){
|
||||||
|
((Unit)b.getOwner()).kill();
|
||||||
|
}
|
||||||
|
b.time(b.lifetime());
|
||||||
|
}
|
||||||
|
};
|
||||||
}};
|
}};
|
||||||
}};
|
}};
|
||||||
|
|
||||||
|
@ -421,7 +421,7 @@ public class Player extends Unit implements BuilderMinerTrait, ShooterTrait{
|
|||||||
public void drawBuildRequests(){
|
public void drawBuildRequests(){
|
||||||
BuildRequest last = null;
|
BuildRequest last = null;
|
||||||
for(BuildRequest request : buildQueue()){
|
for(BuildRequest request : buildQueue()){
|
||||||
if(request.progress > 0.01f || (buildRequest() == request && (dst(request.x * tilesize, request.y * tilesize) <= placeDistance || state.isEditor()))) continue;
|
if(request.progress > 0.01f || (buildRequest() == request && request.initialized && (dst(request.x * tilesize, request.y * tilesize) <= placeDistance || state.isEditor()))) continue;
|
||||||
|
|
||||||
if(request.breaking){
|
if(request.breaking){
|
||||||
Block block = world.ltile(request.x, request.y).block();
|
Block block = world.ltile(request.x, request.y).block();
|
||||||
|
Loading…
Reference in New Issue
Block a user