mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-07-14 17:57:56 +07:00
Fixed #2544
This commit is contained in:
@ -187,7 +187,7 @@ public class Logic implements ApplicationListener{
|
|||||||
//campaign maps do not have a 'win' state!
|
//campaign maps do not have a 'win' state!
|
||||||
if(state.isCampaign()){
|
if(state.isCampaign()){
|
||||||
//gameover only when cores are dead
|
//gameover only when cores are dead
|
||||||
if(!state.rules.attackMode && state.teams.playerCores().size == 0 && !state.gameOver){
|
if(state.teams.playerCores().size == 0 && !state.gameOver){
|
||||||
state.gameOver = true;
|
state.gameOver = true;
|
||||||
Events.fire(new GameOverEvent(state.rules.waveTeam));
|
Events.fire(new GameOverEvent(state.rules.waveTeam));
|
||||||
}
|
}
|
||||||
|
@ -354,7 +354,7 @@ public class DesktopInput extends InputHandler{
|
|||||||
|
|
||||||
table.button(Icon.up, Styles.clearPartiali, () -> {
|
table.button(Icon.up, Styles.clearPartiali, () -> {
|
||||||
ui.planet.show(state.getSector(), player.team().core());
|
ui.planet.show(state.getSector(), player.team().core());
|
||||||
}).visible(() -> state.isCampaign()).tooltip("@launchcore");
|
}).visible(() -> state.isCampaign()).tooltip("@launchcore").disabled(b -> player.team().core() == null);
|
||||||
}
|
}
|
||||||
|
|
||||||
void pollInput(){
|
void pollInput(){
|
||||||
|
@ -88,7 +88,7 @@ public class PausedDialog extends BaseDialog{
|
|||||||
cont.buttonRow("@launchcore", Icon.up, () -> {
|
cont.buttonRow("@launchcore", Icon.up, () -> {
|
||||||
hide();
|
hide();
|
||||||
ui.planet.show(state.getSector(), player.team().core());
|
ui.planet.show(state.getSector(), player.team().core());
|
||||||
});
|
}).disabled(b -> player.team().core() == null);
|
||||||
|
|
||||||
cont.row();
|
cont.row();
|
||||||
|
|
||||||
|
@ -94,6 +94,8 @@ public class PlanetDialog extends BaseDialog implements PlanetInterfaceRenderer{
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void show(Sector sector, CoreBuild launcher){
|
public void show(Sector sector, CoreBuild launcher){
|
||||||
|
if(launcher == null) return;
|
||||||
|
|
||||||
this.launcher = launcher;
|
this.launcher = launcher;
|
||||||
selected = null;
|
selected = null;
|
||||||
hovered = null;
|
hovered = null;
|
||||||
|
Reference in New Issue
Block a user