mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-04 15:27:19 +07:00
Fixed units not rotating to target
This commit is contained in:
@ -14,7 +14,7 @@ import static io.anuke.mindustry.Vars.groundEffectGroup;
|
||||
* Class for creating block rubble on the ground.
|
||||
*/
|
||||
public abstract class Decal extends TimedEntity implements BelowLiquidTrait, DrawTrait{
|
||||
private static final Color color = Color.valueOf("2c2928");
|
||||
private static final Color color = Color.valueOf("3a3635");
|
||||
|
||||
@Override
|
||||
public float lifetime(){
|
||||
|
@ -265,8 +265,10 @@ public abstract class GroundUnit extends BaseUnit{
|
||||
float angle = angleTo(targetTile);
|
||||
|
||||
velocity.add(vec.trns(angleTo(targetTile), type.speed*Time.delta()));
|
||||
if(Units.invalidateTarget(target, this)){
|
||||
rotation = Mathf.slerpDelta(rotation, angle, type.rotatespeed);
|
||||
}
|
||||
}
|
||||
|
||||
protected void moveAwayFromCore(){
|
||||
Team enemy = null;
|
||||
|
Reference in New Issue
Block a user