Examples of IPeripheral


Examples of dan200.computercraft.api.peripheral.IPeripheral

  @Override
  public IPeripheral getPeripheral(TileEntity tile, int side) {
    if (tile == null) return null;

    IPeripheral peripheral = created.get(tile);

    if (peripheral == null) {
      peripheral = super.getPeripheral(tile, side);
      created.put(tile, peripheral);
    }
View Full Code Here

Examples of dan200.computercraft.api.peripheral.IPeripheral

    @Override
    public void addInformation(World world, int x, int y, int z, List<String> infoList){
        infoList.add("blockTracker.info.peripheral.title");
        infoList.add("blockTracker.info.peripheral.availableMethods");
        IPeripheral peripheral = ((IPeripheralProvider)world.getBlock(x, y, z)).getPeripheral(world, x, y, z, 0);
        if(peripheral != null) {
            for(String method : peripheral.getMethodNames()) {
                infoList.add("-" + method);
            }
        }
    }
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.