Package net.minecraft.network.play.client

Examples of net.minecraft.network.play.client.C08PacketPlayerBlockPlacement


    if (isServerWorld(world)) {
      return;
    }
    NetHandlerPlayClient netClientHandler = (NetHandlerPlayClient) FMLClientHandler.instance().getClientPlayHandler();
    netClientHandler.addToSendQueue(new C08PacketPlayerBlockPlacement(x, y, z, hitSide, player.inventory.getCurrentItem(), hitX, hitY, hitZ));
  }
View Full Code Here


            Vector3 f = new Vector3(hit.hitVec).add(-hit.blockX, -hit.blockY, -hit.blockZ);
            Block block = world.getBlock(hit.blockX, hit.blockY, hit.blockZ);
            if(!ignoreActivate(block) && block.onBlockActivated(world, hit.blockX, hit.blockY, hit.blockZ, player, hit.sideHit, (float)f.x, (float)f.y, (float)f.z))
            {
                player.swingItem();
                PacketCustom.sendToServer(new C08PacketPlayerBlockPlacement(
                        hit.blockX, hit.blockY, hit.blockZ, hit.sideHit,
                        player.inventory.getCurrentItem(),
                        (float)f.x, (float)f.y, (float)f.z));
                return true;
            }
View Full Code Here

      Block block = world.getBlock( hit.blockX, hit.blockY, hit.blockZ );
      if ( block != null && !ignoreActivate( block )
          && block.onBlockActivated( world, hit.blockX, hit.blockY, hit.blockZ, player, hit.sideHit, (float) f.x, (float) f.y, (float) f.z ) )
      {
        player.swingItem();
        PacketCustom.sendToServer( new C08PacketPlayerBlockPlacement( hit.blockX, hit.blockY, hit.blockZ, hit.sideHit, player.inventory
            .getCurrentItem(), (float) f.x, (float) f.y, (float) f.z ) );
        return true;
      }
    }
View Full Code Here

TOP

Related Classes of net.minecraft.network.play.client.C08PacketPlayerBlockPlacement

Copyright © 2018 www.massapicom. 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.