Moved logo back over menu
This commit is contained in:
@@ -83,7 +83,7 @@ public class Renderer implements ApplicationListener{
|
|||||||
camera = new Camera();
|
camera = new Camera();
|
||||||
Shaders.init();
|
Shaders.init();
|
||||||
|
|
||||||
Events.on(ResetEvent.class, e -> {
|
Events.on(ResetEvent.class, e -> {
|
||||||
shakeTime = shakeIntensity = 0f;
|
shakeTime = shakeIntensity = 0f;
|
||||||
camShakeOffset.setZero();
|
camShakeOffset.setZero();
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ public class Objectives{
|
|||||||
@Override
|
@Override
|
||||||
public String display(){
|
public String display(){
|
||||||
return Core.bundle.format("requirement.research",
|
return Core.bundle.format("requirement.research",
|
||||||
|
//TODO broken for multi tech nodes.
|
||||||
(content.techNode == null || content.techNode.parent == null || content.techNode.parent.content.unlocked()) && !(content instanceof Item) ?
|
(content.techNode == null || content.techNode.parent == null || content.techNode.parent.content.unlocked()) && !(content instanceof Item) ?
|
||||||
(content.emoji() + " " + content.localizedName) : "???");
|
(content.emoji() + " " + content.localizedName) : "???");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,7 +14,6 @@ import arc.scene.ui.TextButton.*;
|
|||||||
import arc.scene.ui.layout.*;
|
import arc.scene.ui.layout.*;
|
||||||
import arc.struct.*;
|
import arc.struct.*;
|
||||||
import arc.util.*;
|
import arc.util.*;
|
||||||
import mindustry.annotations.Annotations.*;
|
|
||||||
import mindustry.core.*;
|
import mindustry.core.*;
|
||||||
import mindustry.game.EventType.*;
|
import mindustry.game.EventType.*;
|
||||||
import mindustry.gen.*;
|
import mindustry.gen.*;
|
||||||
@@ -42,24 +41,6 @@ public class MenuFragment{
|
|||||||
|
|
||||||
parent.fill((x, y, w, h) -> renderer.render());
|
parent.fill((x, y, w, h) -> renderer.render());
|
||||||
|
|
||||||
String versionText = ((Version.build == -1) ? "[#fc8140aa]" : "[#ffffffba]") + Version.combined();
|
|
||||||
parent.fill((x, y, w, h) -> {
|
|
||||||
TextureRegion logo = Core.atlas.find("logo");
|
|
||||||
float width = Core.graphics.getWidth(), height = Core.graphics.getHeight() - Core.scene.marginTop;
|
|
||||||
float logoscl = Scl.scl(1);
|
|
||||||
float logow = Math.min(logo.width * logoscl, Core.graphics.getWidth() - Scl.scl(20));
|
|
||||||
float logoh = logow * (float)logo.height / logo.width;
|
|
||||||
|
|
||||||
float fx = (int)(width / 2f);
|
|
||||||
float fy = (int)(height - 6 - logoh) + logoh / 2 - (Core.graphics.isPortrait() ? Scl.scl(30f) : 0f);
|
|
||||||
|
|
||||||
Draw.color();
|
|
||||||
Draw.rect(logo, fx, fy, logow, logoh);
|
|
||||||
|
|
||||||
Fonts.outline.setColor(Color.white);
|
|
||||||
Fonts.outline.draw(versionText, fx, fy - logoh/2f - Scl.scl(2f), Align.center);
|
|
||||||
}).touchable = Touchable.disabled;
|
|
||||||
|
|
||||||
parent.fill(c -> {
|
parent.fill(c -> {
|
||||||
c.pane(Styles.noBarPane, cont -> {
|
c.pane(Styles.noBarPane, cont -> {
|
||||||
container = cont;
|
container = cont;
|
||||||
@@ -102,6 +83,24 @@ public class MenuFragment{
|
|||||||
t.getLabel().setColor(becontrol.isUpdateAvailable() ? Tmp.c1.set(Color.white).lerp(Pal.accent, Mathf.absin(5f, 1f)) : Color.white);
|
t.getLabel().setColor(becontrol.isUpdateAvailable() ? Tmp.c1.set(Color.white).lerp(Pal.accent, Mathf.absin(5f, 1f)) : Color.white);
|
||||||
}));
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
String versionText = ((Version.build == -1) ? "[#fc8140aa]" : "[#ffffffba]") + Version.combined();
|
||||||
|
parent.fill((x, y, w, h) -> {
|
||||||
|
TextureRegion logo = Core.atlas.find("logo");
|
||||||
|
float width = Core.graphics.getWidth(), height = Core.graphics.getHeight() - Core.scene.marginTop;
|
||||||
|
float logoscl = Scl.scl(1);
|
||||||
|
float logow = Math.min(logo.width * logoscl, Core.graphics.getWidth() - Scl.scl(20));
|
||||||
|
float logoh = logow * (float)logo.height / logo.width;
|
||||||
|
|
||||||
|
float fx = (int)(width / 2f);
|
||||||
|
float fy = (int)(height - 6 - logoh) + logoh / 2 - (Core.graphics.isPortrait() ? Scl.scl(30f) : 0f);
|
||||||
|
|
||||||
|
Draw.color();
|
||||||
|
Draw.rect(logo, fx, fy, logow, logoh);
|
||||||
|
|
||||||
|
Fonts.outline.setColor(Color.white);
|
||||||
|
Fonts.outline.draw(versionText, fx, fy - logoh/2f - Scl.scl(2f), Align.center);
|
||||||
|
}).touchable = Touchable.disabled;
|
||||||
}
|
}
|
||||||
|
|
||||||
private void buildMobile(){
|
private void buildMobile(){
|
||||||
|
|||||||
Reference in New Issue
Block a user