Makes the top sprite visible on liquid turret icons (#4683)
* Add top region to liquid turret icons * Attempt to change outline icon generation * Draw regions above the outlined icon over it * Draw regions **above** the outlined icon over it * Add clarrifying comment * Implement backwards compatibility for mods * an -> any
This commit is contained in:
@@ -27,6 +27,7 @@ public class LiquidTurret extends Turret{
|
||||
hasLiquids = true;
|
||||
loopSound = Sounds.spray;
|
||||
shootSound = Sounds.none;
|
||||
outlinedIcon = 1;
|
||||
}
|
||||
|
||||
/** Initializes accepted ammo map. Format: [liquid1, bullet1, liquid2, bullet2...] */
|
||||
@@ -63,6 +64,12 @@ public class LiquidTurret extends Turret{
|
||||
super.init();
|
||||
}
|
||||
|
||||
@Override
|
||||
public TextureRegion[] icons(){
|
||||
if(topRegion.found()) return new TextureRegion[]{baseRegion, region, topRegion};
|
||||
return super.icons();
|
||||
}
|
||||
|
||||
public class LiquidTurretBuild extends TurretBuild{
|
||||
@Override
|
||||
public void draw(){
|
||||
|
||||
Reference in New Issue
Block a user