mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-01-05 21:10:53 +07:00
Removed UnitComp#uiIcon()
This commit is contained in:
parent
49489ffadc
commit
31f4957657
@ -40,12 +40,6 @@ abstract class BlockUnitComp implements Unitc{
|
||||
@Replace
|
||||
@Override
|
||||
public TextureRegion icon(){
|
||||
return tile.block.fullIcon;
|
||||
}
|
||||
|
||||
@Replace
|
||||
@Override
|
||||
public TextureRegion uiIcon(){
|
||||
return tile.block.uiIcon;
|
||||
}
|
||||
|
||||
|
@ -74,7 +74,7 @@ abstract class PlayerComp implements UnitController, Entityc, Syncc, Timerc, Dra
|
||||
//display default icon for dead players
|
||||
if(dead()) return core() == null ? UnitTypes.alpha.uiIcon : ((CoreBlock)bestCore().block).unitType.uiIcon;
|
||||
|
||||
return unit.uiIcon();
|
||||
return unit.icon();
|
||||
}
|
||||
|
||||
public boolean displayAmmo(){
|
||||
|
@ -666,13 +666,8 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
|
||||
}
|
||||
}
|
||||
|
||||
/** @return a preview icon for this unit. */
|
||||
public TextureRegion icon(){
|
||||
return type.fullIcon;
|
||||
}
|
||||
|
||||
/** @return a preview UI icon for this unit. */
|
||||
public TextureRegion uiIcon(){
|
||||
public TextureRegion icon(){
|
||||
return type.uiIcon;
|
||||
}
|
||||
|
||||
|
@ -166,7 +166,7 @@ public class MinimapRenderer{
|
||||
if(unit.inFogTo(player.team()) || !unit.type.drawMinimap) continue;
|
||||
|
||||
float scale = Scl.scl(1f) * tilesize * 3;
|
||||
var region = unit.uiIcon();
|
||||
var region = unit.icon();
|
||||
|
||||
Draw.mixcol(unit.team.color, 1f);
|
||||
Draw.rect(region, unit.x, unit.y, scale, scale * (float)region.height / region.width, unit.rotation() - 90);
|
||||
|
Loading…
Reference in New Issue
Block a user