Package com.sk89q.worldedit

Examples of com.sk89q.worldedit.Vector


    private World world;

    @Override
    public Vector getMinimumPoint() {
        return new Vector(0, 0, 0);
    }
View Full Code Here


        return new Vector(0, 0, 0);
    }

    @Override
    public Vector getMaximumPoint() {
        return new Vector(0, 0, 0);
    }
View Full Code Here

     */
    public NonRisingVisitor(Mask mask, RegionFunction function) {
        super(mask, function);
        Collection<Vector> directions = getDirections();
        directions.clear();
        directions.add(new Vector(1, 0, 0));
        directions.add(new Vector(-1, 0, 0));
        directions.add(new Vector(0, 0, 1));
        directions.add(new Vector(0, 0, -1));
        directions.add(new Vector(0, -1, 0));
    }
View Full Code Here

        return new Vector(0, 0, 0);
    }

    @Override
    public Vector getCenter() {
        return new Vector(0, 0, 0);
    }
View Full Code Here

            }

            boolean found = false;
            int groundY = 0;
            for (int y = maxY; y >= minY; --y) {
                Vector test = column.toVector(y);
                if (!found) {
                    if (function.isGround(test)) {
                        found = true;
                        groundY = y;
                    }
View Full Code Here

                if (component.length() > 1) {
                    submask = getBlockMaskComponent(masks, component.substring(1), context);
                } else {
                    submask = new ExistingBlockMask(extent);
                }
                OffsetMask offsetMask = new OffsetMask(submask, new Vector(0, firstChar == '>' ? -1 : 1, 0));
                return new MaskIntersection(offsetMask, Masks.negate(submask));

            case '$':
                Set<BaseBiome> biomes = new HashSet<BaseBiome>();
                String[] biomesList = component.substring(1).split(",");
View Full Code Here

    private int cacheSizeZ;

    public ArbitraryShape(Region extent) {
        this.extent = extent;

        Vector min = extent.getMinimumPoint();
        Vector max = extent.getMaximumPoint();

        cacheOffsetX = min.getBlockX() - 1;
        cacheOffsetY = min.getBlockY() - 1;
        cacheOffsetZ = min.getBlockZ() - 1;

        cacheSizeX = (int) (max.getX() - cacheOffsetX + 2);
        cacheSizeY = (int) (max.getY() - cacheOffsetY + 2);
        cacheSizeZ = (int) (max.getZ() - cacheOffsetZ + 2);

        cache = new short[cacheSizeX * cacheSizeY * cacheSizeZ];
    }
View Full Code Here

        super(extent);
    }

    @Override
    protected BaseBlock getMaterial(int x, int y, int z, BaseBlock defaultMaterial) {
        if (!this.extent.contains(new Vector(x, y, z))) {
            return null;
        }

        return defaultMaterial;
    }
View Full Code Here

        this.zero2 = zero.add(0.5, 0.5, 0.5);
    }

    public BlockVector toWorld(double x, double y, double z) {
        // unscale, unoffset, round-nearest
        return new Vector(x, y, z).multiply(unit).add(zero2).toBlockPoint();
    }
View Full Code Here

        return editSession.getBlockData(toWorld(x, y, z));
    }

    @Override
    public int getBlockTypeAbs(double x, double y, double z) {
        return editSession.getBlockType(new Vector(x, y, z));
    }
View Full Code Here

TOP

Related Classes of com.sk89q.worldedit.Vector

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.