Merge remote-tracking branch 'origin/master'

This commit is contained in:
Anuken 2022-11-01 16:28:30 -04:00
commit 3e6c54069d
4 changed files with 8 additions and 7 deletions

View File

@ -1,5 +1,6 @@
package mindustry.world.blocks.power;
import arc.Core;
import arc.graphics.*;
import arc.graphics.g2d.*;
import arc.math.*;
@ -22,8 +23,8 @@ import static mindustry.Vars.*;
public class BeamNode extends PowerBlock{
public int range = 5;
public @Load("power-beam") TextureRegion laser;
public @Load("power-beam-end") TextureRegion laserEnd;
public @Load(value = "@-beam", fallback = "power-beam") TextureRegion laser;
public @Load(value = "@-beam-end", fallback = "power-beam-end") TextureRegion laserEnd;
public Color laserColor1 = Color.white;
public Color laserColor2 = Color.valueOf("ffd9c2");

View File

@ -22,8 +22,8 @@ public class LongPowerNode extends PowerNode{
public void load(){
super.load();
laser = Core.atlas.find("power-beam");
laserEnd = Core.atlas.find("power-beam-end");
laser = Core.atlas.find(name + "-beam", Core.atlas.find("power-beam"));
laserEnd = Core.atlas.find(name + "-beam-end", Core.atlas.find("power-beam-end"));
}
public class LongPowerNodeBuild extends PowerNodeBuild{

View File

@ -29,8 +29,8 @@ public class PowerNode extends PowerBlock{
/** The maximum range of all power nodes on the map */
protected static float maxRange;
public @Load("laser") TextureRegion laser;
public @Load("laser-end") TextureRegion laserEnd;
public @Load(value = "@-laser", fallback = "laser") TextureRegion laser;
public @Load(value = "@-laser-end", fallback = "laser-end") TextureRegion laserEnd;
public float laserRange = 6;
public int maxNodes = 3;
public boolean autolink = true, drawRange = true;

View File

@ -122,7 +122,7 @@ public class UnitFactory extends UnitBlock{
}
if(plan.unit.unlockedNow()){
t.image(plan.unit.uiIcon).size(40).pad(10f).left();
t.image(plan.unit.uiIcon).size(40).pad(10f).left().scaling(Scaling.fit);
t.table(info -> {
info.add(plan.unit.localizedName).left();
info.row();