Unit selection overlay improvements
This commit is contained in:
@@ -131,7 +131,9 @@ public class OverlayRenderer{
|
||||
Building build = (select instanceof BlockUnitc b ? b.tile() : select instanceof Building b ? b : null);
|
||||
TextureRegion region = build != null ? build.block.fullIcon : select instanceof Unit u ? u.icon() : Core.atlas.white();
|
||||
|
||||
Draw.rect(region, select.getX(), select.getY(), select instanceof Unit u && !(select instanceof BlockUnitc) ? u.rotation - 90f : 0f);
|
||||
if(!(select instanceof Unitc)){
|
||||
Draw.rect(region, select.getX(), select.getY());
|
||||
}
|
||||
|
||||
for(int i = 0; i < 4; i++){
|
||||
float rot = i * 90f + 45f + (-Time.time) % 360f;
|
||||
@@ -255,6 +257,12 @@ public class OverlayRenderer{
|
||||
}
|
||||
}
|
||||
|
||||
public void checkApplySelection(Unit u){
|
||||
if(unitFade > 0 && lastSelect == u){
|
||||
Draw.mixcol(Pal.accent, unitFade);
|
||||
}
|
||||
}
|
||||
|
||||
private static class CoreEdge{
|
||||
float x1, y1, x2, y2;
|
||||
Team t1, t2;
|
||||
|
||||
Reference in New Issue
Block a user