Package net.minecraft.src.buildcraft.api

Examples of net.minecraft.src.buildcraft.api.Position.moveForwards()


            Position entityPos = new Position(pos.x + 0.5, pos.y
                                              + Utils.getPipeFloorOf(stack), pos.z + 0.5,
                                              pos.orientation.reverse());

            entityPos.moveForwards(0.5);

            EntityPassiveItem entity = new EntityPassiveItem(w, entityPos.x,
                    entityPos.y, entityPos.z, stack);

            ((PipeTransportItems) transport).entityEntering(entity,
View Full Code Here


        for (int o = 0; o < 6; ++o) {
            if (Orientations.values()[o] != pos.orientation.reverse()) {
                Position newPos = new Position(pos);
                newPos.orientation = Orientations.values()[o];
                newPos.moveForwards(1.0);

                TileEntity entity = worldObj.getBlockTileEntity((int) newPos.x, (int) newPos.y, (int) newPos.z);

                if (entity instanceof IInventory) {
                    if (new StackUtil(item.item).checkAvailableSlot((IInventory) entity, false, newPos.orientation.reverse())) {
View Full Code Here


        //System.out.println("NewOris Size: " + newOris.size() + " - PO Size: " + possibleOrientations.size() + " - Level: " + Level);
        if (newOris.size() > 0) {
            Position destPos =  new Position(pos.x, pos.y, pos.z, newOris.get( (new Random()) .nextInt(newOris.size()) ) );
            destPos.moveForwards(1.0);
            StackUtil utils = new StackUtil(item.item);
            TileEntity tile = worldObj.getBlockTileEntity((int) destPos.x, (int) destPos.y, (int) destPos.z);

            if (!APIProxy.isClient(worldObj)) {
                if (utils.checkAvailableSlot((IInventory) tile, true, destPos.orientation.reverse()) && utils.items.stackSize == 0) {
View Full Code Here

        int total = 0;
        int ret[] = new int[2];

        for (int i = 0; i < 6; ++i) {
            Position p = new Position(xCoord, yCoord, zCoord, Orientations.values()[i]);
            p.moveForwards(1);

            if (canRec(p)) {
                ret[0]++;
                ret[1] += ((PipeTransportLiquids)this.transport).side[i].average;
            }
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.