Examples of EntityOcelot


Examples of net.minecraft.entity.passive.EntityOcelot

    @SubscribeEvent
    public void changeSittingTaskForOcelots(LivingEvent.LivingUpdateEvent evt)
    {
        if (evt.entityLiving.ticksExisted < 5 && evt.entityLiving instanceof EntityOcelot)
        {
            EntityOcelot ocelot = (EntityOcelot) evt.entityLiving;
            @SuppressWarnings("unchecked")
            List<EntityAITasks.EntityAITaskEntry> tasks = ocelot.tasks.taskEntries;

            for (int i = 0; i < tasks.size(); i++)
            {
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

     * chest.
     */
    public static boolean isOcelotBlockingChest(World par0World, int par1, int par2, int par3)
    {
        Iterator var4 = par0World.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getAABBPool().addOrModifyAABBInPool((double)par1, (double)(par2 + 1), (double)par3, (double)(par1 + 1), (double)(par2 + 2), (double)(par3 + 1))).iterator();
        EntityOcelot var6;

        do
        {
            if (!var4.hasNext())
            {
                return false;
            }

            EntityOcelot var5 = (EntityOcelot)var4.next();
            var6 = (EntityOcelot)var5;
        }
        while (!var6.isSitting());

        return true;
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

    }

    public static boolean isOcelotBlockingChest(World par0World, int par1, int par2, int par3)
    {
        Iterator<?> iterator = par0World.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getBoundingBox(par1, par2 + 1, par3, par1 + 1, par2 + 2, par3 + 1)).iterator();
        EntityOcelot entityocelot;

        do
        {
            if (!iterator.hasNext())
            {
                return false;
            }

            entityocelot = (EntityOcelot) iterator.next();
        }
        while (!entityocelot.isSitting());

        return true;
    }
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

    @SuppressWarnings("rawtypes")
    public static boolean isOcelotBlockingChest(World par0World, int par1, int par2, int par3)
    {
        final Iterator var4 = par0World.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getBoundingBox(par1, par2 + 1, par3, par1 + 1, par2 + 2, par3 + 1)).iterator();
        EntityOcelot var6;

        do
        {
            if (!var4.hasNext())
            {
                return false;
            }

            var6 = (EntityOcelot) var4.next();
        }
        while (!var6.isSitting());

        return true;
    }
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

    @SuppressWarnings("rawtypes")
    public static boolean isOcelotBlockingChest(World par0World, int par1, int par2, int par3)
    {
        final Iterator var4 = par0World.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getBoundingBox(par1, par2 + 1, par3, par1 + 1, par2 + 2, par3 + 1)).iterator();
        EntityOcelot var6;

        do
        {
            if (!var4.hasNext())
            {
                return false;
            }

            final EntityOcelot var5 = (EntityOcelot) var4.next();
            var6 = var5;
        }
        while (!var6.isSitting());

        return true;
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

    @SuppressWarnings("rawtypes")
    public static boolean isOcelotBlockingChest(World par0World, int par1, int par2, int par3)
    {
        final Iterator var4 = par0World.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getBoundingBox(par1, par2 + 1, par3, par1 + 1, par2 + 2, par3 + 1)).iterator();
        EntityOcelot var6;

        do
        {
            if (!var4.hasNext())
            {
                return false;
            }

            final EntityOcelot var5 = (EntityOcelot) var4.next();
            var6 = var5;
        }
        while (!var6.isSitting());

        return true;
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

            modifyAI((EntityAnimal)baby);

            Random rand = this.theAnimal.getRNG();
            if(baby instanceof EntityOcelot) {
                EntityOcelot cat = (EntityOcelot)baby;
                if(rand.nextInt(10) == 0) {
                    cat.setTameSkin(baby.worldObj.rand.nextInt(4));
                }
            }

            double x = rand.nextGaussian() * 0.2D;
            double z = rand.nextGaussian() * 0.2D;
 
View Full Code Here

Examples of net.minecraft.entity.passive.EntityOcelot

    private boolean isCatOnChest() {
        int x = xCoord;
        int y = yCoord;
        int z = zCoord;
        Iterator it = worldObj.getEntitiesWithinAABB(EntityOcelot.class, AxisAlignedBB.getBoundingBox(x, (y + 1), z, (x + 1), (y + 2), (z + 1))).iterator();
        EntityOcelot cat;
        do {
            if (!it.hasNext())
                return false;
            EntityOcelot entityocelot = (EntityOcelot) it.next();
            cat = (EntityOcelot) entityocelot;
        } while (!cat.isSitting());
        return true;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.