Bugfixes / Sprite tweak

This commit is contained in:
Anuken 2019-03-05 09:53:37 -05:00
parent 526a61381d
commit 966efa0669
8 changed files with 17 additions and 16 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 MiB

After

Width:  |  Height:  |  Size: 1.2 MiB

View File

@ -258,7 +258,7 @@ public class TechTree implements ContentList{
private TechNode node(Block block, Runnable children){
ItemStack[] requirements = new ItemStack[block.buildRequirements.length];
for(int i = 0; i < requirements.length; i++){
requirements[i] = new ItemStack(block.buildRequirements[i].item, block.buildRequirements[i].amount * 35);
requirements[i] = new ItemStack(block.buildRequirements[i].item, block.buildRequirements[i].amount * 30);
}
return new TechNode(block, requirements, children);

View File

@ -195,7 +195,7 @@ public class TileEntity extends BaseEntity implements TargetTrait, HealthTrait{
if(other == null) continue;
other = other.target();
if(other.entity == null || other.getTeamID() != tile.getTeamID()) continue;
if(other.entity == null || !(other.interactable(tile.getTeam()))) continue;
other.block().onProximityUpdate(other);

View File

@ -40,7 +40,7 @@ public class HudFragment extends Fragment{
private Table lastUnlockTable;
private Table lastUnlockLayout;
private boolean shown = true;
private float dsize = 58;
private float dsize = 59;
private float isize = 40;
private float coreAttackTime;
@ -58,7 +58,7 @@ public class HudFragment extends Fragment{
select.left();
select.defaults().size(dsize).left();
ImageButton menu = select.addImageButton("icon-menu", "clear", isize, ui.paused::show).get();
select.addImageButton("icon-menu", "clear", isize, ui.paused::show);
flip = select.addImageButton("icon-arrow-up", "clear", isize, this::toggleMenus).get();
select.addImageButton("icon-pause", "clear", isize, () -> {
@ -96,11 +96,11 @@ public class HudFragment extends Fragment{
}
}).get();
select.addImage("blank").color(Pal.accent).width(6f).fillY();
});
select.addImage("blank").color(Pal.accent).width(3f).fillY();
}).left();
cont.row();
cont.addImage("blank").height(6f).color(Pal.accent).fillX();
cont.addImage("blank").height(3f).color(Pal.accent).fillX();
cont.row();
}
@ -121,7 +121,7 @@ public class HudFragment extends Fragment{
addWaveTable(waves);
addPlayButton(btable);
stuff.add(stack).width(dsize * 4 + 6f);
stuff.add(stack).width(dsize * 4 + 3f);
stuff.row();
stuff.table("button", t -> t.margin(10f).add(new Bar("boss.health", Pal.health, () -> state.boss() == null ? 0f : state.boss().healthf()).blink(Color.WHITE))
.grow()).fillX().visible(() -> world.isZone() && state.boss() != null).height(60f).get();
@ -147,9 +147,7 @@ public class HudFragment extends Fragment{
t.table("flat", c -> c.add("$nearpoint")
.update(l -> l.setColor(Tmp.c1.set(Color.WHITE).lerp(Color.SCARLET, Mathf.absin(Time.time(), 10f, 1f))))
.get().setAlignment(Align.center, Align.center))
.margin(6).update(u -> {
u.color.a = Mathf.lerpDelta(u.color.a, Mathf.num(world.spawner.playerNear()), 0.1f);
}).get().color.a = 0f;
.margin(6).update(u -> u.color.a = Mathf.lerpDelta(u.color.a, Mathf.num(world.spawner.playerNear()), 0.1f)).get().color.a = 0f;
});
//out of bounds warning

View File

@ -40,7 +40,7 @@ public class PowerGenerator extends PowerDistributor{
if(hasPower && outputsPower && !consumes.has(ConsumePower.class)){
bars.add("power", entity -> new Bar(() ->
Core.bundle.format("blocks.poweroutput",
Strings.toFixed(entity.tile.block().getPowerProduction(entity.tile)*60, 1)),
Strings.toFixed(entity.tile.block().getPowerProduction(entity.tile)*60 * entity.timeScale, 1)),
() -> Pal.powerBar,
() -> ((GeneratorEntity)entity).productionEfficiency));
}

View File

@ -167,6 +167,9 @@ public class Drill extends Block{
public void update(Tile tile){
DrillEntity entity = tile.entity();
if(Float.isNaN(entity.drillTime)) entity.drillTime = 0f;
if(Float.isNaN(entity.warmup)) entity.warmup = 0f;
if(entity.dominantItem == null){
oreCount.clear();
itemArray.clear();

View File

@ -1,9 +1,11 @@
package io.anuke.mindustry.world.blocks.storage;
import io.anuke.arc.Core;
import io.anuke.arc.graphics.Color;
import io.anuke.annotations.Annotations.Loc;
import io.anuke.annotations.Annotations.Remote;
import io.anuke.arc.Core;
import io.anuke.arc.graphics.Color;
import io.anuke.arc.graphics.g2d.Draw;
import io.anuke.arc.scene.ui.layout.Table;
import io.anuke.mindustry.entities.type.Player;
import io.anuke.mindustry.entities.type.TileEntity;
import io.anuke.mindustry.gen.Call;
@ -11,8 +13,6 @@ import io.anuke.mindustry.type.Item;
import io.anuke.mindustry.world.Block;
import io.anuke.mindustry.world.Tile;
import io.anuke.mindustry.world.blocks.SelectionTrait;
import io.anuke.arc.graphics.g2d.Draw;
import io.anuke.arc.scene.ui.layout.Table;
import java.io.DataInput;
import java.io.DataOutput;