mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-20 20:57:59 +07:00
Fixed some minor bugs with teleporters an changelog
This commit is contained in:
@ -25,8 +25,8 @@ public class DesktopInput extends InputHandler{
|
||||
|
||||
@Override public float getCursorEndX(){ return endx; }
|
||||
@Override public float getCursorEndY(){ return endy; }
|
||||
@Override public float getCursorX(){ return (Graphics.screen(mousex, mousey).x); }
|
||||
@Override public float getCursorY(){ return (Gdx.graphics.getHeight() - 1 - Graphics.screen(mousex, mousey).y); }
|
||||
@Override public float getCursorX(){ return Graphics.screen(mousex, mousey).x; }
|
||||
@Override public float getCursorY(){ return Gdx.graphics.getHeight() - 1 - Graphics.screen(mousex, mousey).y; }
|
||||
@Override public boolean drawPlace(){ return !beganBreak; }
|
||||
|
||||
@Override
|
||||
|
@ -2,6 +2,7 @@ package io.anuke.mindustry.ui.dialogs;
|
||||
|
||||
import com.badlogic.gdx.Gdx;
|
||||
import com.badlogic.gdx.utils.Array;
|
||||
import io.anuke.mindustry.Vars;
|
||||
import io.anuke.mindustry.io.Changelogs;
|
||||
import io.anuke.mindustry.io.Changelogs.VersionInfo;
|
||||
import io.anuke.mindustry.io.Version;
|
||||
@ -17,6 +18,10 @@ public class ChangelogDialog extends FloatingDialog{
|
||||
public ChangelogDialog(){
|
||||
super("$text.changelog.title");
|
||||
|
||||
addCloseButton();
|
||||
|
||||
content().add("$text.changelog.loading");
|
||||
|
||||
Changelogs.getChangelog(result -> {
|
||||
versions = result;
|
||||
Gdx.app.postRunnable(this::setup);
|
||||
@ -30,12 +35,15 @@ public class ChangelogDialog extends FloatingDialog{
|
||||
Table table = new Table();
|
||||
ScrollPane pane = new ScrollPane(table, "clear");
|
||||
|
||||
content().clear();
|
||||
content().add(pane).grow();
|
||||
|
||||
addCloseButton();
|
||||
|
||||
if(versions == null){
|
||||
table.add("$text.changelog.error");
|
||||
if(Vars.android){
|
||||
table.row();
|
||||
table.add("$text.changelog.error.android").padTop(8);
|
||||
}
|
||||
}else{
|
||||
for(VersionInfo info : versions){
|
||||
Table in = new Table("clear");
|
||||
|
@ -122,6 +122,7 @@ public class Block{
|
||||
public void configure(Tile tile, byte data){}
|
||||
|
||||
public void setConfigure(Tile tile, byte data){
|
||||
configure(tile, data);
|
||||
if(Net.active()) NetEvents.handleBlockConfig(tile, data);
|
||||
}
|
||||
|
||||
|
@ -117,7 +117,6 @@ public class Teleporter extends PowerBlock{
|
||||
for(int i = 0; i < colors; i ++){
|
||||
final int f = i;
|
||||
ImageButton button = cont.addImageButton("white", "toggle", 24, () -> {
|
||||
entity.color = (byte)f;
|
||||
lastColor = (byte)f;
|
||||
setConfigure(tile, (byte)f);
|
||||
}).size(34, 38).padBottom(-5.1f).group(group).get();
|
||||
|
Reference in New Issue
Block a user