Actually fixed Serpulo base gen

This commit is contained in:
Anuken
2022-05-09 18:24:27 -04:00
parent 31c5ef2dc5
commit 76f1cfbc07
6 changed files with 17 additions and 15 deletions

View File

@@ -2805,9 +2805,7 @@ public class Blocks{
}} }}
); );
shoot = new ShootAlternate(){{ shoot = new ShootAlternate(3.5f);
spread = 3.5f;
}};
shootY = 3f; shootY = 3f;
reload = 20f; reload = 20f;
@@ -3624,9 +3622,7 @@ public class Blocks{
range = 260f; range = 260f;
inaccuracy = 3f; inaccuracy = 3f;
recoil = 3f; recoil = 3f;
shoot = new ShootAlternate(){{ shoot = new ShootAlternate(8f);
spread = 8f;
}};
shake = 2f; shake = 2f;
size = 4; size = 4;
shootCone = 24f; shootCone = 24f;

View File

@@ -50,7 +50,6 @@ public class Planets{
new HexSkyMesh(this, 2, 0.15f, 0.14f, 5, Color.valueOf("eba768").a(0.75f), 2, 0.42f, 1f, 0.43f), new HexSkyMesh(this, 2, 0.15f, 0.14f, 5, Color.valueOf("eba768").a(0.75f), 2, 0.42f, 1f, 0.43f),
new HexSkyMesh(this, 3, 0.6f, 0.15f, 5, Color.valueOf("eea293").a(0.75f), 2, 0.42f, 1.2f, 0.45f) new HexSkyMesh(this, 3, 0.6f, 0.15f, 5, Color.valueOf("eea293").a(0.75f), 2, 0.42f, 1.2f, 0.45f)
); );
sectorSeed = 1;
alwaysUnlocked = true; alwaysUnlocked = true;
landCloudColor = Color.valueOf("ed6542"); landCloudColor = Color.valueOf("ed6542");
atmosphereColor = Color.valueOf("f07218"); atmosphereColor = Color.valueOf("f07218");
@@ -122,6 +121,7 @@ public class Planets{
new HexSkyMesh(this, 1, 0.6f, 0.16f, 5, Color.white.cpy().lerp(Pal.spore, 0.55f).a(0.75f), 2, 0.45f, 1f, 0.41f) new HexSkyMesh(this, 1, 0.6f, 0.16f, 5, Color.white.cpy().lerp(Pal.spore, 0.55f).a(0.75f), 2, 0.45f, 1f, 0.41f)
); );
sectorSeed = 2;
allowWaves = true; allowWaves = true;
allowWaveSimulation = true; allowWaveSimulation = true;
allowSectorInvasion = true; allowSectorInvasion = true;

View File

@@ -2518,9 +2518,7 @@ public class UnitTypes{
heatColor = Color.valueOf("f9350f"); heatColor = Color.valueOf("f9350f");
cooldownTime = 30f; cooldownTime = 30f;
shoot = new ShootAlternate(){{ shoot = new ShootAlternate(3.5f);
spread = 3.5f;
}};
bullet = new RailBulletType(){{ bullet = new RailBulletType(){{
length = 160f; length = 160f;
@@ -4156,7 +4154,7 @@ public class UnitTypes{
}}; }};
manifold = new ErekirUnitType("manifold"){{ manifold = new ErekirUnitType("manifold"){{
aiController = CargoAI::new; controller = u -> new CargoAI();
isEnemy = false; isEnemy = false;
allowedInPayloads = false; allowedInPayloads = false;
logicControllable = false; logicControllable = false;
@@ -4183,7 +4181,7 @@ public class UnitTypes{
}}; }};
assemblyDrone = new ErekirUnitType("assembly-drone"){{ assemblyDrone = new ErekirUnitType("assembly-drone"){{
aiController = AssemblerAI::new; controller = u -> new AssemblerAI();
flying = true; flying = true;
drag = 0.06f; drag = 0.06f;

View File

@@ -8,6 +8,13 @@ public class ShootAlternate extends ShootPattern{
/** offset of barrel to start on */ /** offset of barrel to start on */
public int barrelOffset = 0; public int barrelOffset = 0;
public ShootAlternate(float spread){
this.spread = spread;
}
public ShootAlternate(){
}
@Override @Override
public void shoot(int totalShots, BulletHandler handler){ public void shoot(int totalShots, BulletHandler handler){
for(int i = 0; i < shots; i++){ for(int i = 0; i < shots; i++){

View File

@@ -82,13 +82,13 @@ public class SerpuloPlanetGenerator extends PlanetGenerator{
any = true; any = true;
} }
if(Structs.contains(tile.tiles, s -> sector.planet.getSector(s).id == sector.planet.startSector)) return;
if(noise < 0.16){ if(noise < 0.16){
for(Ptile other : tile.tiles){ for(Ptile other : tile.tiles){
var osec = sector.planet.getSector(other); var osec = sector.planet.getSector(other);
//no sectors near start sector!
if( if(
osec.id == sector.planet.startSector || //near starting sector
osec.generateEnemyBase && poles < 0.85 || //near other base osec.generateEnemyBase && poles < 0.85 || //near other base
(sector.preset != null && noise < 0.11) //near preset (sector.preset != null && noise < 0.11) //near preset
){ ){

View File

@@ -601,7 +601,8 @@ public class Generators{
//draw treads //draw treads
if(sample instanceof Tankc){ if(sample instanceof Tankc){
image.draw(outline.get(get(type.treadRegion)), true); Pixmap treads = outline.get(get(type.treadRegion));
image.draw(treads, image.width / 2 - treads.width / 2, image.height / 2 - treads.height / 2, true);
image.draw(get(type.previewRegion), true); image.draw(get(type.previewRegion), true);
} }