How can i make Custom Ore Generation?

Discussion in 'Plugin Development' started by AlexanderL123, Nov 16, 2015.

Thread Status:
Not open for further replies.
  1. Offline

    AlexanderL123

    I want to have Netherrack as normal Ore in the Overworld that is so often generated as iron.

    How can i make a Custom Ore Generation?
     
  2. Offline

    Lordloss

  3. Offline

    AlexanderL123

    Is there a way to use Multiverse and make a own generator for it?
     
  4. @AlexanderL123
    Follow the steps in the tutorial, and then you can use /mv create <name> -g <yourpluginname> I believe
     
  5. Offline

    AlexanderL123

    i use now Terrain Control for a custom world but i can only edit resources for every biome and that are lots of biomes :(
    Is there no General Setting for Ores or must i edit every biomconfig?
     
  6. Offline

    mcdorli

    You can create a blockpopulator, ans then add it to a world.
     
  7. Offline

    AlexanderL123

    What is a blockpopulator?
     
  8. Offline

    Abstract97

    @AlexanderL123 Create a class that extends BlockPopulator, then use the WorldInitEvent to check if the world that is initializing is your world, if so you can get that world and add a new instance of the BlockPopulator class you just made.

    Inside that block-populator class, loop through the chunk and add the ores.
     
  9. Offline

    AlexanderL123

    Will this be compatible with Terrain Control or must i delete Terrain Control?
     
  10. Offline

    Abstract97

    @AlexanderL123 Its compatible, by which i don't think it will cause any errors, but terrain control will not be needed for this route.
     
  11. Offline

    mcdorli

    You should think of a blockpopulator as an addon to the world, a blockpopulator creates grass, a another one creates tree, a another one water, etc.
    https://bukkit.org/threads/the-alwa...eneration-part-three-populators-galore.94083/
    You can use World.getPopulators().add(populator), to insert a new populator to the world. The new populator class must extend BlockPopulator and have a populate method. The block populator gets called every time a new chunk get generated, 1 time per chunk. You can then edit all the blocks, in this case, create ore chunk in the chunk
     
  12. Offline

    AlexanderL123

  13. Offline

    mcdorli

    If you still need some more help, I think you can decompile my plugin called extremeTerrain. It is a whole world generator. The ore populator is in the class called ExtremeTerrainOrePopulator, but please, don't copy.
     
Thread Status:
Not open for further replies.

Share This Page