Пример #1
0
  @Override
  public void onEntityCollidedWithBlock(World world, int i, int j, int k, Entity entity) {
    super.onEntityCollidedWithBlock(world, i, j, k, entity);

    Pipe pipe = getPipe(world, i, j, k);

    if (isValid(pipe)) {
      pipe.onEntityCollidedWithBlock(entity);
    }
  }
Пример #2
0
 @Override
 public void onEntityCollidedWithBlock(World world, int x, int y, int z, Entity entity) {
   super.onEntityCollidedWithBlock(world, x, y, z, entity);
   TileEntityWormhole te = (TileEntityWormhole) world.getTileEntity(x, y, z);
   entity.setPosition(te.x, te.y - 2, te.z);
 }