Examples of onHackFinished()


Examples of pneumaticCraft.api.client.pneumaticHelmet.IHackableBlock.onHackFinished()

    @Override
    public void handleClientSide(PacketHackingBlockFinish message, EntityPlayer player){
        IHackableBlock hackableBlock = HackableHandler.getHackableForCoord(player.worldObj, message.x, message.y, message.z, player);
        if(hackableBlock != null) {
            hackableBlock.onHackFinished(player.worldObj, message.x, message.y, message.z, player);
            PneumaticCraft.proxy.getHackTickHandler().trackBlock(new WorldAndCoord(player.worldObj, message.x, message.y, message.z), hackableBlock);
            CommonHUDHandler.getHandlerForPlayer(player).setHackedBlock(null);
            player.worldObj.playSound(message.x, message.y, message.z, "PneumaticCraft:helmetHackFinish", 1.0F, 1.0F, false);
        }
    }
View Full Code Here

Examples of pneumaticCraft.api.client.pneumaticHelmet.IHackableBlock.onHackFinished()

    private void handleHacking(EntityPlayer player){
        if(hackedBlock != null) {
            IHackableBlock hackableBlock = HackableHandler.getHackableForCoord(hackedBlock, player);
            if(hackableBlock != null) {
                if(++hackTime >= hackableBlock.getHackTime(hackedBlock.world, hackedBlock.x, hackedBlock.y, hackedBlock.z, player)) {
                    hackableBlock.onHackFinished(player.worldObj, hackedBlock.x, hackedBlock.y, hackedBlock.z, player);
                    PneumaticCraft.proxy.getHackTickHandler().trackBlock(hackedBlock, hackableBlock);
                    NetworkHandler.sendToAllAround(new PacketHackingBlockFinish(hackedBlock), player.worldObj);
                    setHackedBlock(null);
                }
            } else {
View Full Code Here

Examples of pneumaticCraft.api.client.pneumaticHelmet.IHackableEntity.onHackFinished()

    public void handleClientSide(PacketHackingEntityFinish message, EntityPlayer player){
        Entity entity = player.worldObj.getEntityByID(message.entityId);
        if(entity != null) {
            IHackableEntity hackableEntity = HackableHandler.getHackableForEntity(entity, player);
            if(hackableEntity != null) {
                hackableEntity.onHackFinished(entity, player);
                PneumaticCraft.proxy.getHackTickHandler().trackEntity(entity, hackableEntity);
                CommonHUDHandler.getHandlerForPlayer(player).setHackedEntity(null);
                player.worldObj.playSound(entity.posX, entity.posY, entity.posZ, "PneumaticCraft:helmetHackFinish", 1.0F, 1.0F, false);
            }
        }
View Full Code Here

Examples of pneumaticCraft.api.client.pneumaticHelmet.IHackableEntity.onHackFinished()

            }
        } else if(hackedEntity != null) {
            IHackableEntity hackableEntity = HackableHandler.getHackableForEntity(hackedEntity, player);
            if(hackableEntity != null) {
                if(++hackTime >= hackableEntity.getHackTime(hackedEntity, player)) {
                    hackableEntity.onHackFinished(hackedEntity, player);
                    PneumaticCraft.proxy.getHackTickHandler().trackEntity(hackedEntity, hackableEntity);
                    NetworkHandler.sendToAllAround(new PacketHackingEntityFinish(hackedEntity), new NetworkRegistry.TargetPoint(hackedEntity.worldObj.provider.dimensionId, hackedEntity.posX, hackedEntity.posY, hackedEntity.posZ, 64));
                    setHackedEntity(null);
                }
            } else {
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.