Fixed strange smooth movement of fast ground units

This commit is contained in:
Anuken
2022-09-10 15:02:55 -04:00
parent 3acb449205
commit abb92350c0
4 changed files with 2 additions and 3 deletions

View File

@@ -127,7 +127,7 @@ public class CommandAI extends AIController{
attackTarget != null && unit.within(attackTarget, engageRange) ? engageRange :
unit.isGrounded() ? 0f :
attackTarget != null ? engageRange :
0f, unit.isFlying() ? 40f : 100f, false, null, true);
0f, unit.isFlying() ? 40f : 100f, false, null, targetPos.epsilonEquals(vecOut, 1f));
}
}

View File

@@ -2,7 +2,6 @@ package mindustry.io;
import arc.files.*;
import arc.graphics.*;
import arc.math.geom.*;
import arc.struct.*;
import arc.util.io.*;
import mindustry.content.*;

View File

@@ -409,7 +409,7 @@ public class Conveyor extends Block implements Autotiler{
@Override
public Object senseObject(LAccess sensor){
if(sensor == LAccess.firstItem && len > 0) return ids[Math.max(0, len - 1)];
if(sensor == LAccess.firstItem && len > 0) return ids[len - 1];
return super.senseObject(sensor);
}