Package net.minecraft.dispenser

Examples of net.minecraft.dispenser.IPosition


{
  @Override
  public ItemStack dispenseStack(IBlockSource dispenser, ItemStack stack)
  {
    World world = dispenser.getWorld();
    IPosition dispenserPos = BlockDispenser.getIPositionFromBlockSource(dispenser);
    EnumFacing dispenserFacing = BlockDispenser.getFacing(dispenser.getBlockMetadata());
    EntitySafariNet proj = new EntitySafariNet(world, dispenserPos.getX(), dispenserPos.getY(), dispenserPos.getZ(), stack.copy());
    proj.setThrowableHeading(dispenserFacing.getFrontOffsetX(), dispenserFacing.getFrontOffsetY() + 0.1, dispenserFacing.getFrontOffsetZ(), 1.1F, 6.0F);
    world.spawnEntityInWorld(proj);
    stack.splitStack(1);
    return stack;
  }
View Full Code Here

TOP

Related Classes of net.minecraft.dispenser.IPosition

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.