mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-04 07:17:19 +07:00
Fixed unlocks not clearing / Fixed map editor not updating
This commit is contained in:
@ -222,7 +222,7 @@ public class MapEditorDialog extends Dialog implements Disposable{
|
||||
|
||||
clearChildren();
|
||||
margin(0);
|
||||
build();
|
||||
shown(this::build);
|
||||
|
||||
update(() -> {
|
||||
if(Core.scene.getKeyboardFocus() instanceof Dialog && Core.scene.getKeyboardFocus() != this){
|
||||
@ -382,6 +382,7 @@ public class MapEditorDialog extends Dialog implements Disposable{
|
||||
float size = mobile ? (int) (Math.min(Gdx.graphics.getHeight(), Gdx.graphics.getWidth()) / amount / Unit.dp.scl(1f)) :
|
||||
Math.min(Gdx.graphics.getDisplayMode().height / amount, baseSize);
|
||||
|
||||
clearChildren();
|
||||
table(cont -> {
|
||||
cont.left();
|
||||
|
||||
|
@ -160,7 +160,7 @@ public class SettingsMenuDialog extends SettingsDialog{
|
||||
dialog.content().row();
|
||||
dialog.content().addButton("$text.settings.clearunlocks", "clear", () -> {
|
||||
ui.showConfirm("$text.confirm", "$text.settings.clear.confirm", () -> {
|
||||
Settings.clearBytes("unlocks");
|
||||
control.unlocks.reset();
|
||||
Settings.save();
|
||||
dialog.hide();
|
||||
});
|
||||
|
Reference in New Issue
Block a user