Skip to content

Commit

Permalink
fix ghost block; tweaked lunar berries
Browse files Browse the repository at this point in the history
  • Loading branch information
LeoLezury committed Nov 23, 2024
1 parent 5141ec1 commit 897e6a0
Show file tree
Hide file tree
Showing 16 changed files with 32 additions and 30 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// 1.21.1 2024-11-16T23:00:33.3985306 Registries
// 1.21.1 2024-11-23T19:41:23.3904246 Registries
cdffa512172252fd00a692126bdb2d7e298e84a3 data/eternal_starlight/damage_type/bite.json
7e028d9111c471543bdd218b17976d7a541b1f8b data/eternal_starlight/damage_type/crystalline_infection.json
87798293859822fe3e1c8906d4575bc782e7977f data/eternal_starlight/damage_type/dagger_of_hunger.json
Expand Down Expand Up @@ -86,18 +86,18 @@ e28f8ec9fe6e36b71f38dba2b36e8f0273c44a6e data/eternal_starlight/trim_material/sw
81f925e00a49be4e24f3de767ca6dfa9292bbdf8 data/eternal_starlight/trim_material/thioquartz.json
1d371cf686657e21d39443e45305ffdc5b284331 data/eternal_starlight/trim_pattern/forge.json
0748e5e6fc26503c044ff622af49d067d689492d data/eternal_starlight/trim_pattern/keeper.json
092d77030c8264a397d7cce3944dd56cd791d08d data/eternal_starlight/worldgen/biome/crystallized_desert.json
22986af0020f68c41d2922d275a6e22b6bd9258e data/eternal_starlight/worldgen/biome/dark_swamp.json
31bb40097a9aa69ae032e6455410fff0c9d18e9a data/eternal_starlight/worldgen/biome/ether_river.json
0cfd199fec5a39c20e7a8056e7094a702a823259 data/eternal_starlight/worldgen/biome/scarlet_forest.json
6ac6274317c3208e404277ba4263a319bfeee807 data/eternal_starlight/worldgen/biome/shimmer_river.json
dc29628f7c75fafc27f94b3318bafee77d331b49 data/eternal_starlight/worldgen/biome/starlight_dense_forest.json
1e0ee2a7be1b95e881804b947ce501f4600369bb data/eternal_starlight/worldgen/biome/starlight_forest.json
e28eb2900ec75cb73c7f99de30bfdfc3126cfaa9 data/eternal_starlight/worldgen/biome/starlight_permafrost_forest.json
900624fbc5768bb6934c826154b8fcbf9ad11371 data/eternal_starlight/worldgen/biome/starlit_sea.json
c8489327c452009f4142c4dd0119d6bf08feb9c0 data/eternal_starlight/worldgen/biome/the_abyss.json
36f97b175ada9f4e1b82a2a0dd079235d4af14cd data/eternal_starlight/worldgen/biome/torreya_forest.json
1c07dd4a371c70e3981cea864436e5e0a207937a data/eternal_starlight/worldgen/biome/warm_shore.json
ada000b074cfc4fcb7ab234462cc95edcc3e495a data/eternal_starlight/worldgen/biome/crystallized_desert.json
61ecc100e42d0f17342133da9115ff44ae3382e3 data/eternal_starlight/worldgen/biome/dark_swamp.json
caef124bc20e1bdb711af72384513b80d9db15d2 data/eternal_starlight/worldgen/biome/ether_river.json
696fb14498c3a647d91ebbe8bb439c7a52cef7b3 data/eternal_starlight/worldgen/biome/scarlet_forest.json
721fe216e8a8a5280c724ab4e8f348303e25e1eb data/eternal_starlight/worldgen/biome/shimmer_river.json
d0cfee2031708c1c6db411c88ac4a6ef61668bf7 data/eternal_starlight/worldgen/biome/starlight_dense_forest.json
eb248b134ddd3f74abc84de755a3a3e202eb4251 data/eternal_starlight/worldgen/biome/starlight_forest.json
e546ae9df30eeb4d6a821f713094fd5bb870bbd4 data/eternal_starlight/worldgen/biome/starlight_permafrost_forest.json
e106e913ab65bbded35b18577de626c60fa15036 data/eternal_starlight/worldgen/biome/starlit_sea.json
2e983209d7fc7f344b6c7cc27888361abda25393 data/eternal_starlight/worldgen/biome/the_abyss.json
a4c0ff34a5591f5ac3764a7bc3f4eb8394110990 data/eternal_starlight/worldgen/biome/torreya_forest.json
bd35829e11e2b1faf32a945f297fa4394afc8ba1 data/eternal_starlight/worldgen/biome/warm_shore.json
8640a37510768989b08749d4646198c81b27ee6f data/eternal_starlight/worldgen/configured_carver/caves.json
1c024f2fd00debab5ba1795a253ed9d01e171aca data/eternal_starlight/worldgen/configured_feature/abyssal_kelp.json
91a0720b68af61bf700a1949aff8f2cbb8f13884 data/eternal_starlight/worldgen/configured_feature/abysslate_patch.json
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,6 @@
[],
[
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,6 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
[],
[],
[
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
[],
[],
[
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,12 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
"eternal_starlight:dense_forest",
"eternal_starlight:forest_vegetation"
"eternal_starlight:forest_vegetation",
"eternal_starlight:cave_vine"
],
[
"minecraft:freeze_top_layer",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,12 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
"eternal_starlight:starlight_forest",
"eternal_starlight:forest_vegetation"
"eternal_starlight:forest_vegetation",
"eternal_starlight:cave_vine"
],
[
"minecraft:freeze_top_layer",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
[],
[],
[
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
[],
[],
[
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
"minecraft:patch_tall_grass",
"minecraft:patch_grass_savanna",
"eternal_starlight:waterside_vegetation",
"eternal_starlight:cave_vine",
"eternal_starlight:cave_moss",
"eternal_starlight:cave_moss_vein",
"eternal_starlight:bouldershroom"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ public static BiomeGenerationSettings.Builder baseLandGenBuilder(HolderGetter<Pl
}
BiomeDefaultFeatures.addSurfaceFreezing(builder);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.WATERSIDE_VEGETATION);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_VINE);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_MOSS);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_MOSS_VEIN);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.BOULDERSHROOM);
Expand Down Expand Up @@ -182,7 +181,6 @@ public static BiomeGenerationSettings.Builder baseAquaticGenBuilder(HolderGetter
BiomeGenerationSettings.Builder builder = new BiomeGenerationSettings.Builder(featureGetter, carverGetter);

BiomeDefaultFeatures.addSurfaceFreezing(builder);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_VINE);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_MOSS);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_MOSS_VEIN);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.BOULDERSHROOM);
Expand Down Expand Up @@ -211,6 +209,7 @@ private static BiomeGenerationSettings.Builder forestSettings(HolderGetter<Place
builder.addFeature(GenerationStep.Decoration.RAW_GENERATION, ESPlacedFeatures.FALLEN_LUNAR_LOG);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.STARLIGHT_FOREST);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.FOREST_VEGETATION);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_VINE);
builder.addFeature(GenerationStep.Decoration.LOCAL_MODIFICATIONS, ESPlacedFeatures.STONE_SPIKE);

return builder;
Expand All @@ -222,6 +221,7 @@ private static BiomeGenerationSettings.Builder denseForestSettings(HolderGetter<
builder.addFeature(GenerationStep.Decoration.RAW_GENERATION, ESPlacedFeatures.FALLEN_LUNAR_LOG);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.DENSE_FOREST);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.FOREST_VEGETATION);
builder.addFeature(GenerationStep.Decoration.VEGETAL_DECORATION, ESPlacedFeatures.CAVE_VINE);

return builder;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public class ESBlocks {
properties -> new CeilingHangingSignBlock(ESWoodTypes.LUNAR, properties), BlockBehaviour.Properties.ofFullCopy(Blocks.OAK_HANGING_SIGN).mapColor(MapColor.COLOR_BLACK));
public static final RegistryObject<Block, WallHangingSignBlock> LUNAR_WALL_HANGING_SIGN = register("lunar_wall_hanging_sign",
properties -> new WallHangingSignBlock(ESWoodTypes.LUNAR, properties), BlockBehaviour.Properties.ofFullCopy(Blocks.OAK_WALL_HANGING_SIGN).mapColor(MapColor.COLOR_BLACK));
public static final RegistryObject<Block, SaplingBlock> LUNAR_SAPLING = register("lunar_sapling", properties -> new SaplingBlock(new TreeGrower("lunar", 0.2f, Optional.empty(), Optional.empty(), Optional.of(ESConfiguredFeatures.LUNAR), Optional.of(ESConfiguredFeatures.LUNAR_HUGE), Optional.empty(), Optional.empty()), properties), BlockBehaviour.Properties.ofFullCopy(Blocks.OAK_SAPLING).mapColor(MapColor.COLOR_LIGHT_BLUE));
public static final RegistryObject<Block, SaplingBlock> LUNAR_SAPLING = register("lunar_sapling", properties -> new SaplingBlock(new TreeGrower("lunar", Optional.of(ESConfiguredFeatures.LUNAR_HUGE), Optional.of(ESConfiguredFeatures.LUNAR), Optional.empty()), properties), BlockBehaviour.Properties.ofFullCopy(Blocks.OAK_SAPLING).mapColor(MapColor.COLOR_LIGHT_BLUE));
public static final RegistryObject<Block, FlowerPotBlock> POTTED_LUNAR_SAPLING = register("potted_lunar_sapling", properties -> ESPlatform.INSTANCE.createFlowerPot(() -> (FlowerPotBlock) Blocks.FLOWER_POT, LUNAR_SAPLING, properties), BlockBehaviour.Properties.ofFullCopy(Blocks.POTTED_POPPY).mapColor(MapColor.COLOR_LIGHT_BLUE));

// lunar extras: desert
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import com.mojang.serialization.MapCodec;
import com.mojang.serialization.codecs.RecordCodecBuilder;
import net.minecraft.core.BlockPos;
import net.minecraft.tags.BlockTags;
import net.minecraft.util.RandomSource;
import net.minecraft.util.valueproviders.ConstantInt;
import net.minecraft.util.valueproviders.IntProvider;
Expand Down Expand Up @@ -60,6 +61,17 @@ public List<FoliagePlacer.FoliageAttachment> placeTrunk(LevelSimulatedReader rea
int numBranchesLayer = branchLayerNum.sample(random);
int numBranches = branchNum.sample(random);
int lenBranches = branchLen.sample(random);
// this seems to make no sense, but it actually fixed a stupid block update bug that occurs when a mega tree is placed
// hideous code, but just works
for (int x = 0; x <= 1; x++) {
for (int z = 0; z <= 1; z++) {
BlockPos pos = startPos.offset(x, 0, z);
if (reader.isStateAtPosition(pos, state -> state.isAir() || state.is(BlockTags.SAPLINGS))) {
placer.accept(pos, config.trunkProvider.getState(random, pos));
placer.accept(pos, Blocks.AIR.defaultBlockState());
}
}
}
return placeBranchingTrunk(reader, placer, startPos, random, height, numBranchesLayer, numBranches, lenBranches, config);
}

Expand Down

0 comments on commit 897e6a0

Please sign in to comment.