Examples of addBlock()


Examples of Hexel.things.types.InventoryOwner.addBlock()

            Block b = this.chunks.getBlock(rmBlockAction.x, rmBlockAction.y, rmBlockAction.z, tmp, (Chunk)null);
            if (b.getHealth() < 0) {
              this.chunks.setBlock(rmBlockAction.x, rmBlockAction.y, rmBlockAction.z, BlockEmpty.Make(0), tmp, tmp2, null);
              if (thing instanceof InventoryOwner) {
                InventoryOwner inventoryOwner = (InventoryOwner) thing;
                inventoryOwner.addBlock(b);
              }
            } else {
              Block newB = BlockTools.updateHealth(b, b.getHealth()-1);
              this.chunks.setBlock(rmBlockAction.x, rmBlockAction.y, rmBlockAction.z, newB, tmp, tmp2, null);
            }
View Full Code Here

Examples of biz.source_code.miniTemplator.MiniTemplator.addBlock()

         int dayOfMonth = (weekOfYear*7 + dayOfWeek) - 98;
         if (dayOfMonth >= 1 && dayOfMonth <= 30)
            t.setVariable("dayOfMonth", Integer.toString(dayOfMonth));
          else
            t.setVariable("dayOfMonth", "&nbsp;");
         t.addBlock("day"); }
      t.setVariable("weekOfYear", Integer.toString(weekOfYear));
      t.addBlock("week"); }
   t.generateOutput(outputFileName); }

} // end class Example2
View Full Code Here

Examples of biz.source_code.miniTemplator.MiniTemplator.addBlock()

            t.setVariable("dayOfMonth", Integer.toString(dayOfMonth));
          else
            t.setVariable("dayOfMonth", "&nbsp;");
         t.addBlock("day"); }
      t.setVariable("weekOfYear", Integer.toString(weekOfYear));
      t.addBlock("week"); }
   t.generateOutput(outputFileName); }

} // end class Example2
View Full Code Here

Examples of biz.source_code.miniTemplator.MiniTemplator.addBlock()

public static void main (String args[]) throws Exception {
   MiniTemplator t = new MiniTemplator(templateFileName);
   t.setVariable("animal1", "fox");
   t.setVariable("animal2", "dog");
   t.addBlock("block1");
   t.setVariable("animal1", "horse");
   t.setVariable("animal2", "cow");
   t.addBlock("block1");
   t.generateOutput(outputFileName); }
View Full Code Here

Examples of biz.source_code.miniTemplator.MiniTemplator.addBlock()

   t.setVariable("animal1", "fox");
   t.setVariable("animal2", "dog");
   t.addBlock("block1");
   t.setVariable("animal1", "horse");
   t.setVariable("animal2", "cow");
   t.addBlock("block1");
   t.generateOutput(outputFileName); }

} // end class Example1
View Full Code Here

Examples of de.lv.jvoxgl.world.Chunk.addBlock()

    int cx = (int) Math.floor((float)x/(float)world.getChunkWidth());
    int cz = (int) Math.floor((float)z/(float)world.getChunkDepth());
    if(chunk == null){
      chunk = new Chunk(world, cx, cz);
    }
    if(world.getBlockAt(x, y, z) == null)chunk.addBlock(this, Coordinates.WorldToChunkCoordinatesX(world, x), y, Coordinates.WorldToChunkCoordinatesZ(world, z));
  }

  @Override
  public List<TexturedVertex> getVertices() {
    List<TexturedVertex> vertices = new ArrayList<TexturedVertex>();
View Full Code Here

Examples of edu.mit.blocks.workspace.Page.addBlock()

    Block newBlock;
        newBlock = new Block(workspace, "loop", false);
        FactoryRenderableBlock factoryRenderableBlock = new FactoryRenderableBlock(workspace, manager, newBlock.getBlockID());
        RenderableBlock renderableBlock = factoryRenderableBlock.createNewInstance();
        renderableBlock.setLocation(100, 100);
        page.addBlock(renderableBlock);
       
       
  }
 
  //determine OS
View Full Code Here

Examples of jNab.core.protocol.Packet.addBlock()

  // Playing recorded sound
  Packet p = new Packet();
  MessageBlock mb = new MessageBlock(600);
  mb.addPlayLocalSoundCommand("echo" + this.bunny.getSerialNumber() + ".wav");
  mb.addWaitPreviousEndCommand();
  p.addBlock(mb);
  p.addBlock(new PingIntervalBlock(1));
  this.bunny.addPacket(p);
    }

    /**
 
View Full Code Here

Examples of jNab.core.protocol.Packet.addBlock()

  Packet p = new Packet();
  MessageBlock mb = new MessageBlock(600);
  mb.addPlayLocalSoundCommand("echo" + this.bunny.getSerialNumber() + ".wav");
  mb.addWaitPreviousEndCommand();
  p.addBlock(mb);
  p.addBlock(new PingIntervalBlock(1));
  this.bunny.addPacket(p);
    }

    /**
     * @see jNab.core.events.RecordEventListener#onDoubleRecord(byte[])
View Full Code Here

Examples of jNab.core.protocol.Packet.addBlock()

  {
      MessageBlock mb = new MessageBlock(600);
      mb.addPlayLocalSoundCommand("message" + receiver + ".wav");
      mb.addWaitPreviousEndCommand();
      Packet p = new Packet();
      p.addBlock(mb);
      p.addBlock(new PingIntervalBlock(1));

      this.bunny.getBurrow().getBunny(receiver).addPacket(p);
  }
  catch (NoSuchBunnyException e)
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.