2015-08-29 14:33:25 +02:00
|
|
|
/*
|
|
|
|
* This file ("VillageCustomCropFieldHandler.java") is part of the Actually Additions Mod for Minecraft.
|
|
|
|
* It is created and owned by Ellpeck and distributed
|
|
|
|
* under the Actually Additions License to be found at
|
2016-01-03 16:05:51 +01:00
|
|
|
* http://ellpeck.de/actaddlicense/
|
2015-08-29 14:33:25 +02:00
|
|
|
* View the source code at https://github.com/Ellpeck/ActuallyAdditions
|
|
|
|
*
|
2016-01-03 16:05:51 +01:00
|
|
|
* © 2016 Ellpeck
|
2015-08-29 14:33:25 +02:00
|
|
|
*/
|
|
|
|
|
2016-01-05 04:47:35 +01:00
|
|
|
package de.ellpeck.actuallyadditions.mod.gen;
|
2015-06-29 20:55:56 +02:00
|
|
|
|
|
|
|
import cpw.mods.fml.common.registry.VillagerRegistry;
|
|
|
|
import net.minecraft.world.gen.structure.StructureVillagePieces;
|
|
|
|
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.Random;
|
|
|
|
|
|
|
|
public class VillageCustomCropFieldHandler implements VillagerRegistry.IVillageCreationHandler{
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public StructureVillagePieces.PieceWeight getVillagePieceWeight(Random random, int i){
|
2015-07-06 23:41:10 +02:00
|
|
|
return new StructureVillagePieces.PieceWeight(VillageComponentCustomCropField.class, 5, 1);
|
2015-06-29 20:55:56 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public Class<?> getComponentClass(){
|
|
|
|
return VillageComponentCustomCropField.class;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public Object buildComponent(StructureVillagePieces.PieceWeight villagePiece, StructureVillagePieces.Start startPiece, List pieces, Random random, int p1, int p2, int p3, int p4, int p5){
|
|
|
|
return VillageComponentCustomCropField.buildComponent(pieces, p1, p2, p3, p4);
|
|
|
|
}
|
|
|
|
}
|