Search in sources :

Example 1 with DepositFeature

use of com.oitsjustjose.geolosys.common.world.feature.DepositFeature in project Geolosys by oitsjustjose.

the class PlutonRegistry method onBiomesLoaded.

@SubscribeEvent
public void onBiomesLoaded(BiomeLoadingEvent evt) {
    BiomeGenerationSettingsBuilder settings = evt.getGeneration();
    // Removes vanilla ores
    if (CommonConfig.REMOVE_VANILLA_ORES.get()) {
        for (GenerationStage.Decoration deco : decorations) {
            FeatureUtils.destroyFeature(settings.getFeatures(deco), OreRemover.filterFeatures(settings.getFeatures(deco)));
        }
    }
    DepositFeature o = new DepositFeature(NoFeatureConfig.CODEC);
    settings.withFeature(GenerationStage.Decoration.UNDERGROUND_ORES, o.withConfiguration(NoFeatureConfig.NO_FEATURE_CONFIG));
}
Also used : GenerationStage(net.minecraft.world.gen.GenerationStage) DepositFeature(com.oitsjustjose.geolosys.common.world.feature.DepositFeature) BiomeGenerationSettingsBuilder(net.minecraftforge.common.world.BiomeGenerationSettingsBuilder) SubscribeEvent(net.minecraftforge.eventbus.api.SubscribeEvent)

Aggregations

DepositFeature (com.oitsjustjose.geolosys.common.world.feature.DepositFeature)1 GenerationStage (net.minecraft.world.gen.GenerationStage)1 BiomeGenerationSettingsBuilder (net.minecraftforge.common.world.BiomeGenerationSettingsBuilder)1 SubscribeEvent (net.minecraftforge.eventbus.api.SubscribeEvent)1