mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-02-02 20:33:50 +07:00
Fixed #7622
This commit is contained in:
parent
5e734dfd59
commit
4735e28aad
@ -119,21 +119,11 @@ public class CommandAI extends AIController{
|
||||
}
|
||||
}
|
||||
|
||||
boolean noBoost = true;
|
||||
|
||||
if(targetPos != null){
|
||||
boolean move = true;
|
||||
vecOut.set(targetPos);
|
||||
|
||||
//boosting units with RTS controls are incredibly buggy and hard to use. there's no clear way for units to know where to land to approach or attack something
|
||||
boolean tryBoosting = false;//unit.type.canBoost && (attackTarget == null || !unit.within(attackTarget, unit.type.range));
|
||||
//noBoost = false;
|
||||
|
||||
if(tryBoosting){
|
||||
unit.updateBoosting(true);
|
||||
}
|
||||
|
||||
if(unit.isGrounded() && !tryBoosting){
|
||||
if(unit.isGrounded()){
|
||||
move = Vars.controlPath.getPathPosition(unit, pathId, targetPos, vecOut);
|
||||
}
|
||||
|
||||
@ -185,10 +175,6 @@ public class CommandAI extends AIController{
|
||||
}else if(target != null){
|
||||
faceTarget();
|
||||
}
|
||||
|
||||
if(noBoost){
|
||||
unit.updateBoosting(false);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -5746,7 +5746,6 @@ public class Blocks{
|
||||
requirements(Category.logic, with(Items.copper, 90, Items.lead, 50, Items.silicon, 50));
|
||||
|
||||
instructionsPerTick = 2;
|
||||
|
||||
size = 1;
|
||||
}};
|
||||
|
||||
@ -5754,9 +5753,7 @@ public class Blocks{
|
||||
requirements(Category.logic, with(Items.lead, 320, Items.silicon, 80, Items.graphite, 60, Items.thorium, 50));
|
||||
|
||||
instructionsPerTick = 8;
|
||||
|
||||
range = 8 * 22;
|
||||
|
||||
size = 2;
|
||||
}};
|
||||
|
||||
|
@ -64,6 +64,8 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
|
||||
}
|
||||
|
||||
public void updateBoosting(boolean boost){
|
||||
if(!type.canBoost) return;
|
||||
|
||||
elevation = Mathf.approachDelta(elevation, type.canBoost ? Mathf.num(boost || onSolid() || (isFlying() && !canLand())) : 0f, type.riseSpeed);
|
||||
}
|
||||
|
||||
|
@ -23,7 +23,7 @@ public enum Gamemode{
|
||||
rules.waveTimer = true;
|
||||
|
||||
rules.waveSpacing = 2f * Time.toMinutes;
|
||||
rules.teams.get(rules.waveTeam).infiniteResources = true;
|
||||
rules.waveTeam.rules().infiniteResources = true;
|
||||
}, map -> map.teams.size > 1),
|
||||
pvp(rules -> {
|
||||
rules.pvp = true;
|
||||
|
Loading…
Reference in New Issue
Block a user