So basically what I would like to do is check the Y value of the world, and then add a mob to a spawn list. I've already tried this a few ways, it'd be great to get some ideas that I haven't tried yet. Hopefully one will work.
// This makes bat to spawn only below sea level.
@ForgeSubscribe
public void mobypos(CheckSpawn event)
{
if (event.entityLiving.getEntityName().equals("Bat") && event.entityLiving.posY > 63)
{
event.setResult(Event.Result.DENY);
}
}
Sweet thanks Could I do something similar to this to check the block it's spawning on? So it would only spawn on a certain block?