Misc minor fixes & cost balance
This commit is contained in:
@@ -21,7 +21,7 @@ public class CommandAI extends AIController{
|
|||||||
/** All encountered unreachable buildings of this AI. Why a sequence? Because contains() is very rarely called on it. */
|
/** All encountered unreachable buildings of this AI. Why a sequence? Because contains() is very rarely called on it. */
|
||||||
public IntSeq unreachableBuildings = new IntSeq(8);
|
public IntSeq unreachableBuildings = new IntSeq(8);
|
||||||
|
|
||||||
protected boolean stopAtTarget;
|
protected boolean stopAtTarget, stopWhenInRange;
|
||||||
protected Vec2 lastTargetPos;
|
protected Vec2 lastTargetPos;
|
||||||
protected int pathId = -1;
|
protected int pathId = -1;
|
||||||
protected Seq<Unit> local = new Seq<>(false);
|
protected Seq<Unit> local = new Seq<>(false);
|
||||||
@@ -194,6 +194,11 @@ public class CommandAI extends AIController{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(stopWhenInRange && targetPos != null && unit.within(targetPos, engageRange - 1f)){
|
||||||
|
targetPos = null;
|
||||||
|
stopWhenInRange = false;
|
||||||
|
}
|
||||||
|
|
||||||
}else if(target != null){
|
}else if(target != null){
|
||||||
faceTarget();
|
faceTarget();
|
||||||
}
|
}
|
||||||
@@ -240,10 +245,15 @@ public class CommandAI extends AIController{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void commandPosition(Vec2 pos){
|
public void commandPosition(Vec2 pos){
|
||||||
|
commandPosition(pos, false);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void commandPosition(Vec2 pos, boolean stopWhenInRange){
|
||||||
targetPos = pos;
|
targetPos = pos;
|
||||||
lastTargetPos = pos;
|
lastTargetPos = pos;
|
||||||
attackTarget = null;
|
attackTarget = null;
|
||||||
pathId = Vars.controlPath.nextTargetId();
|
pathId = Vars.controlPath.nextTargetId();
|
||||||
|
this.stopWhenInRange = stopWhenInRange;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void commandTarget(Teamc moveTo){
|
public void commandTarget(Teamc moveTo){
|
||||||
|
|||||||
@@ -2543,7 +2543,7 @@ public class Blocks{
|
|||||||
fluxReactor = new VariableReactor("flux-reactor"){{
|
fluxReactor = new VariableReactor("flux-reactor"){{
|
||||||
requirements(Category.power, with(Items.graphite, 300, Items.carbide, 200, Items.oxide, 100, Items.silicon, 600, Items.surgeAlloy, 300));
|
requirements(Category.power, with(Items.graphite, 300, Items.carbide, 200, Items.oxide, 100, Items.silicon, 600, Items.surgeAlloy, 300));
|
||||||
powerProduction = 120f;
|
powerProduction = 120f;
|
||||||
maxHeat = 150f;
|
maxHeat = 140f;
|
||||||
|
|
||||||
consumeLiquid(Liquids.cyanogen, 9f / 60f);
|
consumeLiquid(Liquids.cyanogen, 9f / 60f);
|
||||||
liquidCapacity = 30f;
|
liquidCapacity = 30f;
|
||||||
@@ -2934,7 +2934,7 @@ public class Blocks{
|
|||||||
}};
|
}};
|
||||||
|
|
||||||
coreCitadel = new CoreBlock("core-citadel"){{
|
coreCitadel = new CoreBlock("core-citadel"){{
|
||||||
requirements(Category.effect, with(Items.silicon, 4000, Items.beryllium, 5000, Items.tungsten, 3000, Items.oxide, 1000));
|
requirements(Category.effect, with(Items.silicon, 4000, Items.beryllium, 4000, Items.tungsten, 3000, Items.oxide, 1000));
|
||||||
|
|
||||||
unitType = UnitTypes.incite;
|
unitType = UnitTypes.incite;
|
||||||
health = 16000;
|
health = 16000;
|
||||||
|
|||||||
@@ -3055,7 +3055,6 @@ public class UnitTypes{
|
|||||||
trailWidth = 2f;
|
trailWidth = 2f;
|
||||||
trailLength = 4;
|
trailLength = 4;
|
||||||
shake = 1f;
|
shake = 1f;
|
||||||
recoil = 0.1f;
|
|
||||||
|
|
||||||
trailEffect = Fx.missileTrail;
|
trailEffect = Fx.missileTrail;
|
||||||
trailParam = 1.8f;
|
trailParam = 1.8f;
|
||||||
@@ -3093,6 +3092,7 @@ public class UnitTypes{
|
|||||||
recoil = 0.5f;
|
recoil = 0.5f;
|
||||||
|
|
||||||
bullet = new BulletType(){{
|
bullet = new BulletType(){{
|
||||||
|
shootSound = Sounds.lasershoot;
|
||||||
shootEffect = Fx.sparkShoot;
|
shootEffect = Fx.sparkShoot;
|
||||||
hitEffect = Fx.pointHit;
|
hitEffect = Fx.pointHit;
|
||||||
maxRange = 100f;
|
maxRange = 100f;
|
||||||
|
|||||||
Reference in New Issue
Block a user