Generation tweaks
This commit is contained in:
@@ -49,8 +49,8 @@ public class Vars implements Loadable{
|
||||
public static final ContentType[] defaultContentIcons = {ContentType.item, ContentType.liquid, ContentType.block, ContentType.unit};
|
||||
/** Wall darkness radius. */
|
||||
public static final int darkRadius = 4;
|
||||
/** Maximum extra padding around deployment schematics. */
|
||||
public static final int maxLoadoutSchematicPad = 5;
|
||||
/** Maximum extra padding around deployment schematics. TODO 4, or 5?*/
|
||||
public static final int maxLoadoutSchematicPad = 4;
|
||||
/** Maximum schematic size.*/
|
||||
public static final int maxSchematicSize = 32;
|
||||
/** All schematic base64 starts with this string.*/
|
||||
|
||||
@@ -134,6 +134,7 @@ public class Blocks{
|
||||
tankAssembler,
|
||||
shipAssembler,
|
||||
mechAssembler,
|
||||
//TODO maybe making it 5x5 would be more appropriate, seems kinda cheap.
|
||||
basicAssemblerModule,
|
||||
|
||||
//payloads
|
||||
@@ -143,6 +144,7 @@ public class Blocks{
|
||||
message, switchBlock, microProcessor, logicProcessor, hyperProcessor, largeLogicDisplay, logicDisplay, memoryCell, memoryBank,
|
||||
|
||||
//campaign
|
||||
//TODO launch pad on erekir, 5x5, uses nuclear(?) fuel
|
||||
launchPad, interplanetaryAccelerator
|
||||
|
||||
;
|
||||
|
||||
@@ -86,8 +86,8 @@ public class ErekirPlanetGenerator extends PlanetGenerator{
|
||||
|
||||
if(ice < 0.6){
|
||||
if(result == Blocks.rhyolite || result == Blocks.yellowStone || result == Blocks.regolith){
|
||||
//TODO bio(?) luminescent stuff
|
||||
return Blocks.ferricStone; //TODO perhaps something else. what about ice?
|
||||
//TODO bio(?) luminescent stuff? ice?
|
||||
return Blocks.carbonStone; //TODO perhaps something else.
|
||||
}
|
||||
}
|
||||
|
||||
@@ -273,13 +273,13 @@ public class ErekirPlanetGenerator extends PlanetGenerator{
|
||||
}
|
||||
|
||||
//TODO design ore generation so it doesn't overlap
|
||||
if(noise(x + 999, y + 600 - x, 4, 0.63f, 50f, 1f) < 0.25f && floor == Blocks.crystallineStone){
|
||||
if(noise(x + 999, y + 600 - x, 4, 0.63f, 45f, 1f) < 0.29f && floor == Blocks.crystallineStone){
|
||||
ore = Blocks.oreCrystalThorium;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
if(noise(x + 999, y + 600 - x, 5, 0.8f, 50f, 1f) < 0.38f && floor == Blocks.crystallineStone){
|
||||
if(noise(x + 999, y + 600 - x, 5, 0.8f, 45f, 1f) < 0.44f && floor == Blocks.crystallineStone){
|
||||
floor = Blocks.crystalFloor;
|
||||
}
|
||||
|
||||
@@ -350,7 +350,7 @@ public class ErekirPlanetGenerator extends PlanetGenerator{
|
||||
while(ventCount < minVents && iterations++ < maxIterations){
|
||||
outer:
|
||||
for(Tile tile : tiles){
|
||||
if(rand.chance(0.00017)){
|
||||
if(rand.chance(0.00018)){
|
||||
int radius = 1;
|
||||
for(int x = -radius; x <= radius; x++){
|
||||
for(int y = -radius; y <= radius; y++){
|
||||
@@ -401,6 +401,7 @@ public class ErekirPlanetGenerator extends PlanetGenerator{
|
||||
decoration(0.017f);
|
||||
|
||||
//not allowed
|
||||
//TODO use Items.serpuloItems
|
||||
state.rules.hiddenBuildItems.addAll(Items.copper, Items.titanium, Items.coal, Items.lead, Items.blastCompound, Items.pyratite, Items.sporePod, Items.metaglass, Items.plastanium);
|
||||
|
||||
//it is very hot
|
||||
|
||||
@@ -194,7 +194,7 @@ public class SerpuloPlanetGenerator extends PlanetGenerator{
|
||||
|
||||
void joinLiquid(int x1, int y1, int x2, int y2){
|
||||
float nscl = rand.random(100f, 140f) * 6f;
|
||||
int rad = rand.random(5, 10);
|
||||
int rad = rand.random(7, 11);
|
||||
int avoid = 2 + rad;
|
||||
var path = pathfind(x1, y1, x2, y2, tile -> (tile.solid() || !tile.floor().isLiquid ? 70f : 0f) + noise(tile.x, tile.y, 2, 0.4f, 1f / nscl) * 500, Astar.manhattan);
|
||||
path.each(t -> {
|
||||
|
||||
@@ -73,6 +73,7 @@ public class LaunchPad extends Block{
|
||||
|
||||
@Override
|
||||
public boolean shouldConsume(){
|
||||
//TODO do not consume after reload / disable?
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -122,7 +123,9 @@ public class LaunchPad extends Block{
|
||||
if(!state.isCampaign()) return;
|
||||
|
||||
//increment launchCounter then launch when full and base conditions are met
|
||||
if((launchCounter += edelta()) >= launchTime && edelta() >= 0.001f && items.total() >= itemCapacity){
|
||||
if((launchCounter += edelta()) >= launchTime && consValid() && items.total() >= itemCapacity){
|
||||
//if there are item requirements, use those.
|
||||
consume();
|
||||
launchSound.at(x, y);
|
||||
LaunchPayload entity = LaunchPayload.create();
|
||||
items.each((item, amount) -> entity.stacks.add(new ItemStack(item, amount)));
|
||||
|
||||
Reference in New Issue
Block a user