UI fixes; fixed conveyor infinite item pileup

This commit is contained in:
Anuken 2017-12-07 14:45:04 -05:00
parent 475efc38d2
commit 956e35b677
6 changed files with 19 additions and 12 deletions

View File

@ -48,7 +48,8 @@ io.anuke.ucore.scene.ui.ImageTextButton$ImageTextButtonStyle: {
toggle: {checked: button-down, down: button-down, up: button, font: default-font, fontColor: white, over: button-over, disabled: button, disabledFontColor: grey }
},
io.anuke.ucore.scene.ui.ScrollPane$ScrollPaneStyle: {
default: {background: border, vScroll: scroll, vScrollKnob: scroll-knob-vertical}
default: {background: border, vScroll: scroll, vScrollKnob: scroll-knob-vertical},
clear: {vScroll: scroll, vScrollKnob: scroll-knob-vertical}
},
io.anuke.ucore.scene.ui.Window$WindowStyle: {
default: {titleFont: default-font, background: window, titleFontColor: orange },

View File

@ -38,7 +38,7 @@ import io.anuke.ucore.util.*;
public class Renderer extends RendererModule{
String[] surfaces = { "shadow", "shield", "pixel", "indicators" };
int targetscale = baseCameraScale;
int chunksize = 32;
int chunksize = 16;
int[][][] cache;
FloatArray shieldHits = new FloatArray();
float shieldHitDuration = 18f;

View File

@ -171,23 +171,29 @@ public class BlocksFragment implements Fragment{
GameState.set(State.paused);
FloatingDialog d = new FloatingDialog("Block Info");
Table table = new Table();
table.defaults().pad(1f).units(Unit.dp);
ScrollPane pane = new ScrollPane(table, "clear");
pane.setFadeScrollBars(false);
Table top = new Table();
top.left();
top.add(new Image(Draw.region(recipe.result.name))).size(8*5 * recipe.result.width).units(Unit.dp);
top.add("[orange]"+recipe.result.formalName).padLeft(6f).units(Unit.dp);
d.content().add(top).fill().left();
d.content().row();
d.content().add(desclabel).width(600).units(Unit.dp);
d.content().row();
table.add(top).fill().left();
table.row();
table.add(desclabel).width(600).units(Unit.dp);
table.row();
d.content().add(pane).grow();
if(statlist.size > 0){
d.content().add("[coral][[extra block info]:").padTop(6).padBottom(5).left();
d.content().row();
table.add("[coral][[extra block info]:").padTop(6).padBottom(5).left();
table.row();
}
for(String s : statlist){
d.content().add(s).left();
d.content().row();
table.add(s).left();
table.row();
}
d.buttons().addButton("OK", ()->{

View File

@ -120,7 +120,7 @@ public class Conveyor extends Block{
int direction = source == null ? 0 : Math.abs(source.relativeTo(dest.x, dest.y) - dest.getRotation());
float minitem = dest.<ConveyorEntity>entity().minitem;
return ((direction == 0) && minitem > 0.05f) ||
((direction %2 == 1) && minitem > 0.5f);
((direction %2 == 1) && minitem > 0.52f);
}
@Override

Binary file not shown.

View File

@ -17,7 +17,7 @@ public class DesktopLauncher {
Lwjgl3ApplicationConfiguration config = new Lwjgl3ApplicationConfiguration();
config.setTitle("Mindustry");
config.setMaximized(true);
config.useVsync(false);
//config.useVsync(false);
config.setWindowedMode(800, 600);
config.setWindowIcon("sprites/icon.png");