mirror of
https://github.com/Anuken/Mindustry.git
synced 2025-02-11 11:17:11 +07:00
Fixed map-3 waves
This commit is contained in:
parent
47e639be28
commit
f6093c864f
Binary file not shown.
@ -1,9 +1,5 @@
|
||||
package mindustry.content;
|
||||
|
||||
import arc.math.geom.*;
|
||||
import mindustry.game.*;
|
||||
import mindustry.game.MapObjectives.*;
|
||||
import mindustry.graphics.*;
|
||||
import mindustry.type.*;
|
||||
|
||||
import static mindustry.content.Planets.*;
|
||||
@ -128,6 +124,7 @@ public class SectorPresets{
|
||||
three = new SectorPreset("three", erekir, 36){{
|
||||
difficulty = 5;
|
||||
captureWave = 9;
|
||||
attackAfterWaves = true;
|
||||
}};
|
||||
|
||||
atlas = new SectorPreset("atlas", erekir, 14){{ //TODO random sector, pick a better one
|
||||
|
@ -291,7 +291,14 @@ public class Logic implements ApplicationListener{
|
||||
if(state.rules.waves && (state.enemies == 0 && state.rules.winWave > 0 && state.wave >= state.rules.winWave && !spawner.isSpawning()) ||
|
||||
(state.rules.attackMode && state.rules.waveTeam.cores().isEmpty())){
|
||||
|
||||
Call.sectorCapture();
|
||||
if(state.rules.sector.preset != null && state.rules.sector.preset.attackAfterWaves && !state.rules.attackMode){
|
||||
//activate attack mode to destroy cores after waves are done.
|
||||
state.rules.attackMode = true;
|
||||
state.rules.waves = false;
|
||||
Call.setRules(state.rules);
|
||||
}else{
|
||||
Call.sectorCapture();
|
||||
}
|
||||
}
|
||||
}else{
|
||||
if(!state.rules.attackMode && state.teams.playerCores().size == 0 && !state.gameOver){
|
||||
|
@ -18,6 +18,8 @@ public class SectorPreset extends UnlockableContent{
|
||||
public float startWaveTimeMultiplier = 2f;
|
||||
public boolean addStartingItems = false;
|
||||
public boolean showSectorLandInfo = true;
|
||||
/** If true, switches to attack mode after waves end. */
|
||||
public boolean attackAfterWaves = false;
|
||||
|
||||
public SectorPreset(String name, Planet planet, int sector){
|
||||
super(name);
|
||||
|
Loading…
Reference in New Issue
Block a user