CanadianGamer

ModOreGeneration

Feb 11th, 2025
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.77 KB | None | 0 0
  1. package com.randommod.world.gen;
  2.  
  3. import com.randommod.world.ModPlacedFeatures;
  4. import net.fabricmc.fabric.api.biome.v1.BiomeModifications;
  5. import net.fabricmc.fabric.api.biome.v1.BiomeSelectors;
  6. import net.minecraft.world.gen.GenerationStep;
  7.  
  8. public class ModOreGeneration {
  9.  
  10. public static void generateOres() {
  11. BiomeModifications.addFeature(BiomeSelectors.foundInOverworld(), GenerationStep.Feature.UNDERGROUND_ORES,
  12. ModPlacedFeatures.RANDOMITE_ORE_PLACED_KEY);
  13.  
  14. // Example for individual Bioms
  15. // BiomeModifications.addFeature(BiomeSelectors.includeByKey(BiomeKeys.FOREST, BiomeKeys.PLAINS),
  16. // GenerationStep.Feature.UNDERGROUND_ORES,
  17. // ModPlacedFeatures.PINK_GARNET_ORE_PLACED_KEY);
  18.  
  19.  
  20. }
  21.  
  22. }
  23.  
Advertisement
Add Comment
Please, Sign In to add comment