Package pneumaticCraft.common.ai

Examples of pneumaticCraft.common.ai.StringFilterEntitySelector


        return "entityAttack";
    }

    @Override
    public List<EntityLivingBase> getValidEntities(World world){
        StringFilterEntitySelector whitelistFilter = new StringFilterEntitySelector();
        StringFilterEntitySelector blacklistFilter = new StringFilterEntitySelector();

        ProgWidgetString widget = (ProgWidgetString)getConnectedParameters()[1];
        if(widget != null) {
            while(widget != null) {
                whitelistFilter.addEntry(widget.string);
                widget = (ProgWidgetString)widget.getConnectedParameters()[0];
            }
        } else {
            whitelistFilter.setFilter("");
        }

        widget = (ProgWidgetString)getConnectedParameters()[3];
        while(widget != null) {
            blacklistFilter.addEntry(widget.string);
            widget = (ProgWidgetString)widget.getConnectedParameters()[0];
        }

        List<Entity> entities = ProgWidgetAreaItemBase.getEntitiesInArea((ProgWidgetArea)getConnectedParameters()[0], (ProgWidgetArea)getConnectedParameters()[2], world, whitelistFilter, blacklistFilter);
        List<EntityLivingBase> livingEntities = new ArrayList<EntityLivingBase>();
View Full Code Here


              }*/

        }
        AxisAlignedBB bbBox = AxisAlignedBB.getBoundingBox(xCoord - grateRange, yCoord - grateRange, zCoord - grateRange, xCoord + grateRange + 1, yCoord + grateRange + 1, zCoord + grateRange + 1);
        List<Entity> entities = worldObj.selectEntitiesWithinAABB(Entity.class, bbBox, new StringFilterEntitySelector().setFilter(entityFilter));
        double d0 = grateRange + 0.5D;
        for(Entity entity : entities) {
            if(!entity.worldObj.isRemote && entity.getDistanceSq(xCoord + 0.5D, yCoord + 0.5D, zCoord + 0.5D) < 0.5D && entity instanceof EntityItem && !entity.isDead) {
                List<IInventory> inventories = new ArrayList<IInventory>();
                List<Integer> sides = new ArrayList<Integer>();
View Full Code Here

        itemFilter.useModSimilarity = useModSimilarity;
        return itemFilter;
    }

    public void addWhitelistText(String text){
        if(whitelistFilter == null) whitelistFilter = new StringFilterEntitySelector();
        whitelistFilter.addEntry(text);
    }
View Full Code Here

        if(whitelistFilter == null) whitelistFilter = new StringFilterEntitySelector();
        whitelistFilter.addEntry(text);
    }

    public void addBlacklistText(String text){
        if(blacklistFilter == null) blacklistFilter = new StringFilterEntitySelector();
        blacklistFilter.addEntry(text);
    }
View Full Code Here

TOP

Related Classes of pneumaticCraft.common.ai.StringFilterEntitySelector

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.