Skip to content

Commit

Permalink
bloom foliage now generates
Browse files Browse the repository at this point in the history
  • Loading branch information
NewJumper committed Oct 27, 2023
1 parent d91c06f commit d29a8e0
Show file tree
Hide file tree
Showing 9 changed files with 95 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
// 1.20.1 2023-10-21T23:32:47.3915637 Registries
c92ff9d09d1e634b03702ed2548052b8dd904e91 data/deeperdarker/dimension_type/otherside.json
4722285e5c50f018e9423f4e719e9a5dd67c3bd8 data/deeperdarker/worldgen/biome/blooming_caverns.json
// 1.20.1 2023-10-27T17:39:45.0208373 Registries
67f8cd0621b1c3614da8c1910f6b7bcb61660293 data/deeperdarker/dimension_type/otherside.json
1087b644ded881bbbf5188fd66ce16f07cc59fbf data/deeperdarker/worldgen/biome/blooming_caverns.json
16372ebfc8f36cee32a93f72d13073bb98639882 data/deeperdarker/worldgen/biome/deeplands.json
bd2c433caf3a3f7dfff3668a68dbdf56fa994df5 data/deeperdarker/worldgen/biome/echoing_forest.json
06d29b9291ed3a63be90750a8c6f182e0c168b7b data/deeperdarker/worldgen/biome/overcast_columns.json
799c485ec1466bd9b459c4ca9e2e2d5963465cc3 data/deeperdarker/worldgen/configured_feature/blooming_sculk_patch.json
3510820741c1f596035b74223ec273786b6dcbad data/deeperdarker/worldgen/configured_feature/blooming_sculk_vegetation.json
5097028f5c8ae5e294126d6df771e3126d4fbd07 data/deeperdarker/worldgen/configured_feature/gloomslate_column.json
ba29dfa84f2bebe688044c6e89b6c1d38dbaf0c6 data/deeperdarker/worldgen/configured_feature/gloomslate_generation.json
5d330f021ad1e22b038b08bfd79b49f5da654254 data/deeperdarker/worldgen/configured_feature/gloomy_sculk_patch.json
Expand Down Expand Up @@ -44,6 +45,7 @@ ee40c6672e01f7903cbd018effd3b9fb238b9dc8 data/deeperdarker/worldgen/configured_f
8d9c10bf4c7aa2ff2fa6f7aa8c3b646ab05433b9 data/deeperdarker/worldgen/configured_feature/surface_sculk_stone.json
853f5d90238319461c608dc077bc999afe6b8bcb data/deeperdarker/worldgen/configured_feature/tree_echo.json
34fb9a5e22128132e9fb0b0a7700008873e4ac41 data/deeperdarker/worldgen/placed_feature/blooming_moss.json
fe37fcf58645ddec579c794a106fbcff6e32c041 data/deeperdarker/worldgen/placed_feature/blooming_sculk_vegetation.json
cc0ab13e199295089d8269584cc7aa83b3595c9b data/deeperdarker/worldgen/placed_feature/echo_soil.json
e18687e9b7d94385510ea85e00af1ba4e24e32ec data/deeperdarker/worldgen/placed_feature/echo_tree.json
739dfb25c8e5de7a098ca0c9a256cc28d890e63c data/deeperdarker/worldgen/placed_feature/gloomslate_coal.json
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
[],
[],
[
"deeperdarker:blooming_sculk_vegetation",
"deeperdarker:sculk_tendrils",
"deeperdarker:sculk_vines"
]
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"type": "minecraft:vegetation_patch",
"config": {
"depth": 1,
"extra_bottom_block_chance": 0.0,
"extra_edge_column_chance": 0.5,
"ground_state": {
"type": "minecraft:simple_state_provider",
"state": {
"Name": "deeperdarker:blooming_sculk"
}
},
"replaceable": "#deeperdarker:gloomy_sculk_replaceable",
"surface": "floor",
"vegetation_chance": 0.1,
"vegetation_feature": {
"feature": "deeperdarker:blooming_sculk_vegetation",
"placement": []
},
"vertical_range": 2,
"xz_radius": {
"type": "minecraft:uniform",
"value": {
"max_inclusive": 2,
"min_inclusive": 1
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"type": "minecraft:simple_block",
"config": {
"to_place": {
"type": "minecraft:weighted_state_provider",
"entries": [
{
"data": {
"Name": "deeperdarker:blooming_flowers",
"Properties": {
"facing": "north"
}
},
"weight": 1
},
{
"data": {
"Name": "deeperdarker:glowing_grass"
},
"weight": 1
}
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"feature": "deeperdarker:blooming_sculk_patch",
"placement": [
{
"type": "minecraft:count",
"count": 256
},
{
"type": "minecraft:in_square"
},
{
"type": "minecraft:height_range",
"height": {
"type": "minecraft:uniform",
"max_inclusive": {
"absolute": 256
},
"min_inclusive": {
"above_bottom": 0
}
}
},
{
"type": "minecraft:biome"
}
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ public class DDConfiguredFeatures {
public static final ResourceKey<ConfiguredFeature<?, ?>> SURFACE_SCULK_STONE = createKey("surface_sculk_stone");
public static final ResourceKey<ConfiguredFeature<?, ?>> SCULK_DECORATION = createKey("sculk_decoration");
public static final ResourceKey<ConfiguredFeature<?, ?>> SCULK_PATCH = createKey("sculk_patch");
public static final ResourceKey<ConfiguredFeature<?, ?>> BLOOMING_SCULK_VEGETATION = createKey("blooming_sculk_vegetation");
public static final ResourceKey<ConfiguredFeature<?, ?>> BLOOMING_SCULK_PATCH = createKey("blooming_sculk_patch");
public static final ResourceKey<ConfiguredFeature<?, ?>> GLOOMSLATE_GENERATION = createKey("gloomslate_generation");
public static final ResourceKey<ConfiguredFeature<?, ?>> SURFACE_GLOOMSLATE = createKey("surface_gloomslate");
public static final ResourceKey<ConfiguredFeature<?, ?>> GLOOMY_SCULK_VEGETATION = createKey("gloomy_sculk_vegetation");
Expand Down Expand Up @@ -115,6 +117,8 @@ public static void bootstrap(BootstapContext<ConfiguredFeature<?, ?>> context) {
FeatureUtils.register(context, SURFACE_SCULK_STONE, Feature.VEGETATION_PATCH, new VegetationPatchConfiguration(DDTags.Blocks.SCULK_REPLACEABLES, new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(Blocks.SCULK.defaultBlockState(), 1).add(DDBlocks.SCULK_STONE.get().defaultBlockState(), 2)), PlacementUtils.inlinePlaced(configuredFeatures.getOrThrow(SCULK_STONE_GENERATION)), CaveSurface.FLOOR, ConstantInt.of(1), 0, 2, 0, UniformInt.of(1, 2), 0.3f));
FeatureUtils.register(context, SCULK_DECORATION, Feature.SIMPLE_BLOCK, new SimpleBlockConfiguration(new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(Blocks.SCULK_VEIN.defaultBlockState().setValue(PipeBlock.DOWN, true), 47).add(Blocks.SCULK_SENSOR.defaultBlockState(), 16).add(Blocks.SCULK_CATALYST.defaultBlockState(), 2).add(Blocks.SCULK_SHRIEKER.defaultBlockState().setValue(BlockStateProperties.CAN_SUMMON, true), 1))));
FeatureUtils.register(context, SCULK_PATCH, Feature.VEGETATION_PATCH, new VegetationPatchConfiguration(DDTags.Blocks.SCULK_REPLACEABLES, new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(Blocks.SCULK.defaultBlockState(), 6).add(DDBlocks.SCULK_STONE.get().defaultBlockState(), 2).add(DDBlocks.SCULK_GRIME.get().defaultBlockState(), 1)), PlacementUtils.inlinePlaced(configuredFeatures.getOrThrow(SCULK_DECORATION)), CaveSurface.FLOOR, ConstantInt.of(1), 0, 2, 0.2f, UniformInt.of(2, 3), 0.3f));
FeatureUtils.register(context, BLOOMING_SCULK_VEGETATION, Feature.SIMPLE_BLOCK, new SimpleBlockConfiguration(new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(DDBlocks.BLOOMING_FLOWERS.get().defaultBlockState(), 1).add(DDBlocks.GLOWING_GRASS.get().defaultBlockState(), 1))));
FeatureUtils.register(context, BLOOMING_SCULK_PATCH, Feature.VEGETATION_PATCH, new VegetationPatchConfiguration(DDTags.Blocks.GLOOMY_SCULK_REPLACEABLE, BlockStateProvider.simple(DDBlocks.BLOOMING_SCULK.get()), PlacementUtils.inlinePlaced(configuredFeatures.getOrThrow(BLOOMING_SCULK_VEGETATION)), CaveSurface.FLOOR, ConstantInt.of(1), 0, 2, 0.1f, UniformInt.of(1, 2), 0.5f));
FeatureUtils.register(context, GLOOMSLATE_GENERATION, Feature.SIMPLE_BLOCK, new SimpleBlockConfiguration(BlockStateProvider.simple(DDBlocks.GLOOMSLATE.get())));
FeatureUtils.register(context, SURFACE_GLOOMSLATE, Feature.VEGETATION_PATCH, new VegetationPatchConfiguration(DDTags.Blocks.GLOOMSLATE_REPLACEABLE, new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(DDBlocks.GLOOMY_SCULK.get().defaultBlockState(), 4).add(DDBlocks.GLOOMSLATE.get().defaultBlockState(), 1)), PlacementUtils.inlinePlaced(configuredFeatures.getOrThrow(GLOOMSLATE_GENERATION)), CaveSurface.FLOOR, ConstantInt.of(1), 0, 2, 0, ConstantInt.of(2), 0.3f));
FeatureUtils.register(context, GLOOMY_SCULK_VEGETATION, Feature.SIMPLE_BLOCK, new SimpleBlockConfiguration(new WeightedStateProvider(SimpleWeightedRandomList.<BlockState>builder().add(DDBlocks.GLOOMY_GRASS.get().defaultBlockState(), 9).add(DDBlocks.GLOOMY_CACTUS.get().defaultBlockState(), 1))));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ public class DDPlacedFeatures {

public static final ResourceKey<PlacedFeature> SURFACE_SCULK_STONE = createKey("surface_sculk_stone");
public static final ResourceKey<PlacedFeature> SCULK_DECORATION = createKey("sculk_decoration");
public static final ResourceKey<PlacedFeature> BLOOMING_SCULK_VEGETATION = createKey("blooming_sculk_vegetation");
public static final ResourceKey<PlacedFeature> SURFACE_GLOOMSLATE = createKey("surface_gloomslate");
public static final ResourceKey<PlacedFeature> GLOOMY_SCULK_VEGETATION = createKey("gloomy_sculk_vegetation");

Expand Down Expand Up @@ -70,6 +71,7 @@ public static void bootstrap(BootstapContext<PlacedFeature> context) {

PlacementUtils.register(context, SURFACE_SCULK_STONE, features.getOrThrow(DDConfiguredFeatures.SURFACE_SCULK_STONE), countPlacement(55, PlacementUtils.RANGE_BOTTOM_TO_MAX_TERRAIN_HEIGHT));
PlacementUtils.register(context, SCULK_DECORATION, features.getOrThrow(DDConfiguredFeatures.SCULK_PATCH), countPlacement(86, PlacementUtils.RANGE_BOTTOM_TO_MAX_TERRAIN_HEIGHT));
PlacementUtils.register(context, BLOOMING_SCULK_VEGETATION, features.getOrThrow(DDConfiguredFeatures.BLOOMING_SCULK_PATCH), countPlacement(256, PlacementUtils.RANGE_BOTTOM_TO_MAX_TERRAIN_HEIGHT));
PlacementUtils.register(context, SURFACE_GLOOMSLATE, features.getOrThrow(DDConfiguredFeatures.SURFACE_GLOOMSLATE), countPlacement(32, PlacementUtils.RANGE_BOTTOM_TO_MAX_TERRAIN_HEIGHT));
PlacementUtils.register(context, GLOOMY_SCULK_VEGETATION, features.getOrThrow(DDConfiguredFeatures.GLOOMY_SCULK_PATCH), countPlacement(256, PlacementUtils.RANGE_BOTTOM_TO_MAX_TERRAIN_HEIGHT));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ private static Biome bloomingCaverns(HolderGetter<PlacedFeature> placedFeatures,
mobSpawnBuilder.addSpawn(MobCategory.MONSTER, new MobSpawnSettings.SpawnerData(DDEntities.SCULK_SNAPPER.get(), 1, 1, 2));

BiomeGenerationSettings.Builder biomeBuilder = new BiomeGenerationSettings.Builder(placedFeatures, worldCarvers);
biomeBuilder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, DDPlacedFeatures.BLOOMING_SCULK_VEGETATION);
biomeBuilder.addFeature(GenerationStep.Decoration.UNDERGROUND_ORES, DDPlacedFeatures.BLOOMING_MOSS);
addSculkDecoration(biomeBuilder);
addSculkOres(biomeBuilder);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public class OthersideDimension {
public static final ResourceKey<DimensionType> OTHERSIDE = ResourceKey.create(Registries.DIMENSION_TYPE, new ResourceLocation(DeeperDarker.MOD_ID, "otherside"));

public static void bootstrap(BootstapContext<DimensionType> context) {
context.register(OTHERSIDE, new DimensionType(OptionalLong.of(18000L), false, true, false, true, 1, true, false, 0, 128, 128, DDTags.Blocks.INFINIBURN_OTHERSIDE, BuiltinDimensionTypes.NETHER_EFFECTS, 0.05f, new DimensionType.MonsterSettings(true, false, ConstantInt.of(7), 9)));
context.register(OTHERSIDE, new DimensionType(OptionalLong.of(18000L), false, true, false, true, 1, true, false, 0, 128, 128, DDTags.Blocks.INFINIBURN_OTHERSIDE, BuiltinDimensionTypes.NETHER_EFFECTS, 0.05f, new DimensionType.MonsterSettings(true, false, ConstantInt.of(7), 15)));
}

public static final DeferredRegister<PoiType> POI = DeferredRegister.create(ForgeRegistries.POI_TYPES, DeeperDarker.MOD_ID);
Expand Down

0 comments on commit d29a8e0

Please sign in to comment.