Package net.minecraftforge.common.util

Examples of net.minecraftforge.common.util.ForgeDirection


    if(world.isRemote) {
      return true;
    }

    ForgeDirection dir = ForgeDirection.values()[side];
    int placeX = x + dir.offsetX;
    int placeY = y + dir.offsetY;
    int placeZ = z + dir.offsetZ;

    if(player.canPlayerEdit(placeX, placeY, placeZ, side, itemStack) && world.isAirBlock(placeX, placeY, placeZ)
View Full Code Here


      }
      return true;

    } else {

      ForgeDirection dir = ForgeDirection.values()[side];
      int placeX = x + dir.offsetX;
      int placeY = y + dir.offsetY;
      int placeZ = z + dir.offsetZ;

      if(world.getBlock(placeX, placeY, placeZ) == EnderIO.blockConduitBundle) {
View Full Code Here

  public void spawnParticle(int type)
  {
    if(type == 0)
    {
      ForgeDirection side = ForgeDirection.getOrientation(facing);

      double x = xCoord + (side.offsetX == 0 ? 0.5 : Math.max(side.offsetX, 0));
      double z = zCoord + (side.offsetZ == 0 ? 0.5 : Math.max(side.offsetZ, 0));

      worldObj.spawnParticle("smoke", x, yCoord + 0.5, z, 0.0D, 0.0D, 0.0D);
View Full Code Here

    return Coord4D.get(this).translate(0, 2, 0).getTileEntity(worldObj);
  }

  public TileEntity getEjectInv()
  {
    ForgeDirection side = ForgeDirection.getOrientation(facing).getOpposite();

    return new Coord4D(xCoord+(side.offsetX*2), yCoord+1, zCoord+(side.offsetZ*2), worldObj.provider.dimensionId).getTileEntity(worldObj);
  }
View Full Code Here

    return InventoryUtils.EMPTY;
  }

  public TileEntity getEjectTile()
  {
    ForgeDirection side = ForgeDirection.getOrientation(facing).getOpposite();
    return new Coord4D(xCoord+side.offsetX, yCoord+1, zCoord+side.offsetZ, worldObj.provider.dimensionId).getTileEntity(worldObj);
  }
View Full Code Here

  }

  @Override
  public int[] getBoundSlots(Coord4D location, int side)
  {
    ForgeDirection dir = ForgeDirection.getOrientation(facing).getOpposite();

    Coord4D eject = Coord4D.get(this).translate(dir.offsetX, 1, dir.offsetZ);
    Coord4D pull = Coord4D.get(this).translate(0, 1, 0);

    if((location.equals(eject) && side == dir.ordinal()) || (location.equals(pull) && side == 1))
    {
      if(EJECT_INV == null)
      {
        EJECT_INV = new int[27];
View Full Code Here

  }

  @Override
  public boolean canBoundInsert(Coord4D location, int i, ItemStack itemstack)
  {
    ForgeDirection side = ForgeDirection.getOrientation(facing).getOpposite();

    Coord4D eject = Coord4D.get(this).translate(side.offsetX, 1, side.offsetZ);
    Coord4D pull = Coord4D.get(this).translate(0, 1, 0);

    if(location.equals(eject))
View Full Code Here

  }

  @Override
  public boolean canBoundExtract(Coord4D location, int i, ItemStack itemstack, int j)
  {
    ForgeDirection side = ForgeDirection.getOrientation(facing).getOpposite();

    Coord4D eject = new Coord4D(xCoord+side.offsetX, yCoord+1, zCoord+side.offsetZ, worldObj.provider.dimensionId);
    Coord4D pull = new Coord4D(xCoord, yCoord+1, zCoord, worldObj.provider.dimensionId);

    if(location.equals(eject))
View Full Code Here

    return ret;
  }

  public boolean buildStructure()
  {
    ForgeDirection right = MekanismUtils.getRight(facing);

    height = 0;
    controllerConflict = false;
    updatedThisTick = true;
   
View Full Code Here

    return structured;
  }

  public boolean scanTopLayer(Coord4D current)
  {
    ForgeDirection left = MekanismUtils.getLeft(facing);
    ForgeDirection back = MekanismUtils.getBack(facing);

    for(int x = 0; x < 4; x++)
    {
      for(int z = 0; z < 4; z++)
      {
View Full Code Here

TOP

Related Classes of net.minecraftforge.common.util.ForgeDirection

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.