Examples of shouldDrop()


Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

    public boolean replace(boolean shouldDrop)
    {
        CHBlockHealEvent event = new CHBlockHealEvent(block, shouldDrop, CHBlockHealReason.BURNT);
        Bukkit.getPluginManager().callEvent(event);
        if (event.isCancelled())
            return event.shouldDrop();
        return block.replace(event.shouldDrop());
    }

    /**
     * Get the Replaceable represented.
View Full Code Here

Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

    {
        CHBlockHealEvent event = new CHBlockHealEvent(block, shouldDrop, CHBlockHealReason.BURNT);
        Bukkit.getPluginManager().callEvent(event);
        if (event.isCancelled())
            return event.shouldDrop();
        return block.replace(event.shouldDrop());
    }

    /**
     * Get the Replaceable represented.
     *
 
View Full Code Here

Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

        while (iter.hasNext())
        {
            Replaceable block = iter.next();
            CHBlockHealEvent event = new CHBlockHealEvent(block, shouldDrop, reason);
            Bukkit.getPluginManager().callEvent(event);
            if (!event.isCancelled() && block.replace(event.shouldDrop()))
                iter.remove();
        }
        if (shouldDrop)
        {
            blockList.clear();
View Full Code Here

Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

        if (blockList.isEmpty())
            return;
        block = blockList.remove();
        CHBlockHealEvent event = new CHBlockHealEvent(block, false, CHBlockHealReason.BLOCK_BY_BLOCK);
        Bukkit.getPluginManager().callEvent(event);
        if (!event.isCancelled() && !block.replace(event.shouldDrop()))
            block.delayReplacement(CHBlockHealReason.BLOCK_BY_BLOCK);
        if (CreeperConfig.getBool(CfgVal.TELEPORT_ON_SUFFOCATE))
            Suffocating.checkPlayerOneBlock(block.getBlock().getLocation());
    }
View Full Code Here

Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

            else
            {
                CHBlockHealEvent event = new CHBlockHealEvent(blockState, true, reason);
                Bukkit.getPluginManager().callEvent(event);
                if (!event.isCancelled())
                    blockState.replace(event.shouldDrop());
                Bukkit.getScheduler().cancelTask(id);
            }
        }
        else
        {
View Full Code Here

Examples of com.nitnelave.CreeperHeal.events.CHBlockHealEvent.shouldDrop()

        else
        {
            CHBlockHealEvent event = new CHBlockHealEvent(blockState, true, reason);
            Bukkit.getPluginManager().callEvent(event);
            if (!event.isCancelled())
                blockState.replace(event.shouldDrop());
            Bukkit.getScheduler().cancelTask(id);
        }

    }
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.