Added an accessor for villagers

This commit is contained in:
CovertJaguar 2013-01-07 14:55:17 -08:00
parent 550928735e
commit 224d933564

View file

@ -4,6 +4,8 @@ import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.Random;
import java.util.Collection;
import java.util.Collections;
import net.minecraft.entity.passive.EntityVillager;
import net.minecraft.item.Item;
@ -149,6 +151,15 @@ public class VillagerRegistry
return defaultSkin;
}
/**
* Returns a list of all added villager types
*
* @return newVillagerIds
*/
public static Collection<Integer> getRegisteredVillagers()
{
return Collections.unmodifiableCollection(instance().newVillagerIds);
}
/**
* Callback to handle trade setup for villagers
*