Package codechicken.lib.vec

Examples of codechicken.lib.vec.Vector3


                case 3: z1 = bc.z+0.5+shift; break;
                case 4: x1 = bc.x+0.5-shift; break;
                case 5: x1 = bc.x+0.5+shift; break;
            }

            return new Vector3(x1, y1, z1);
        }
View Full Code Here


        @Override
        public ParticleLogic clone()
        {
            ParticleLogicPipeRouterFlow logic = new ParticleLogicPipeRouterFlow(start, dir, color, approachSpeed, targetDistance);
            logic.setTarget(new Vector3(targetX, targetY, targetZ));
            return logic;
        }
View Full Code Here

                    torches.add((RedstoneTorchModel)m);

            for (RedstoneTorchModel m : torches)
                if (m.on && rand.nextInt(torches.size()) == 0)
                {
                    Vector3 pos = new Vector3(rand.nextFloat(), rand.nextFloat(), rand.nextFloat()).add(-0.5).multiply(0.05, 0.1, 0.05);
                    pos.add(m.lightPos);// height
                    pos.apply(part.rotationT()).add(part.x(), part.y(), part.z());
                    part.world().spawnParticle("reddust", pos.x, pos.y, pos.z, 0, 0, 0);
                }
        }
View Full Code Here

      return false;

    if ( world.isRemote && !player.isSneaking() )// attempt to use block activated like normal and tell the server
                            // the right stuff
    {
      Vector3 f = new Vector3( hit.hitVec ).add( -hit.blockX, -hit.blockY, -hit.blockZ );
      Block block = world.getBlock( hit.blockX, hit.blockY, hit.blockZ );
      if ( block != null && !ignoreActivate( block )
          && block.onBlockActivated( world, hit.blockX, hit.blockY, hit.blockZ, player, hit.sideHit, (float) f.x, (float) f.y, (float) f.z ) )
      {
        player.swingItem();
View Full Code Here

{
    public Vector3 vec;
    public UV uv;

    public Vertex5() {
        this(new Vector3(), new UV());
    }
View Full Code Here

    public Vertex5(double x, double y, double z, double u, double v) {
        this(x, y, z, u, v, 0);
    }

    public Vertex5(double x, double y, double z, double u, double v, int tex) {
        this(new Vector3(x, y, z), new UV(u, v, tex));
    }
View Full Code Here

    @Override
    public boolean onItemUse(ItemStack stack, EntityPlayer player, World w, int x, int y, int z, int side, float hitX, float hitY, float hitZ){
        if(FMP.getMultiPart(w, new ChunkPosition(x, y, z), PartPressureTube.class) != null || w.getBlock(x, y, z) == Blockss.pressureTube) {
            BlockCoord pos = new BlockCoord(x, y, z);
            Vector3 vhit = new Vector3(hitX, hitY, hitZ);
            double d = getHitDepth(vhit, side);
            if(d < 1 && place(stack, player, pos, w, side, vhit)) {
                w.playSoundEffect(x + 0.5, y + 0.5, z + 0.5, Block.soundTypeGlass.getStepResourcePath(), Block.soundTypeGlass.getVolume() * 5.0F, Block.soundTypeGlass.getPitch() * .9F);
                return true;
            } else {
View Full Code Here

TOP

Related Classes of codechicken.lib.vec.Vector3

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.