Crash fixes
This commit is contained in:
@@ -115,7 +115,7 @@ public class HudFragment extends Fragment{
|
||||
int index = 0;
|
||||
for(Element elem : children){
|
||||
int fi = index++;
|
||||
Core.scene.add(elem);
|
||||
parent.add(elem);
|
||||
elem.visible(() -> {
|
||||
if(fi < 4){
|
||||
elem.setSize(size);
|
||||
@@ -392,7 +392,7 @@ public class HudFragment extends Fragment{
|
||||
t.add("$saveload");
|
||||
});
|
||||
|
||||
blockfrag.build(Core.scene.root);
|
||||
blockfrag.build(parent);
|
||||
}
|
||||
|
||||
@Remote(targets = Loc.both, forward = true, called = Loc.both)
|
||||
|
||||
@@ -11,7 +11,6 @@ import io.anuke.arc.scene.event.Touchable;
|
||||
import io.anuke.arc.scene.style.TextureRegionDrawable;
|
||||
import io.anuke.arc.scene.ui.*;
|
||||
import io.anuke.arc.scene.ui.layout.Table;
|
||||
import io.anuke.mindustry.core.GameState.State;
|
||||
import io.anuke.mindustry.entities.type.TileEntity;
|
||||
import io.anuke.mindustry.game.EventType.UnlockEvent;
|
||||
import io.anuke.mindustry.game.EventType.WorldLoadEvent;
|
||||
@@ -117,7 +116,7 @@ public class PlacementFragment extends Fragment{
|
||||
public void build(Group parent){
|
||||
parent.fill(full -> {
|
||||
toggler = full;
|
||||
full.bottom().right().visible(() -> !state.is(State.menu) && ui.hudfrag.shown());
|
||||
full.bottom().right().visible(() -> ui.hudfrag.shown());
|
||||
|
||||
full.table(frame -> {
|
||||
InputHandler input = control.input();
|
||||
|
||||
Reference in New Issue
Block a user