BuildVisibility non-enum / Canvas is now shown

This commit is contained in:
Anuken
2022-09-23 12:27:44 -04:00
parent 710fd3484f
commit 8b9cbc2c7c
6 changed files with 36 additions and 15 deletions

View File

@@ -119,11 +119,21 @@ public class CommandAI extends AIController{
}
}
boolean noBoost = true;
if(targetPos != null){
boolean move = true;
vecOut.set(targetPos);
if(unit.isGrounded()){
//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){
move = Vars.controlPath.getPathPosition(unit, pathId, targetPos, vecOut);
}
@@ -175,6 +185,10 @@ public class CommandAI extends AIController{
}else if(target != null){
faceTarget();
}
if(noBoost){
unit.updateBoosting(false);
}
}
@Override