	@Override
	public void run() {

		long timestamp = System.currentTimeMillis();

		skipped = 0;
		chunks = 0;
		machines = 0;
		map_chunk.clear();
		map_machine.clear();
		time = 0;
		map_chunktime.clear();
		skipped_chunks.clear();
		map_machinetime.clear();
		block_timings.clear();

		final Map<Location, Integer> bugged = new HashMap<Location, Integer>(bugged_blocks);
		bugged_blocks.clear();

		Map<Location, Boolean> remove = new HashMap<Location, Boolean>(delete);

		for (Map.Entry<Location, Boolean> entry: remove.entrySet()) {
			BlockStorage._integrated_removeBlockInfo(entry.getKey(), entry.getValue());
			delete.remove(entry.getKey());
		}

		if (!HALTED) {
			for (final String c: BlockStorage.getTickingChunks()) {
				long timestamp2 = System.currentTimeMillis();
				chunks++;

				blocks:
				for (final Location l: BlockStorage.getTickingLocations(c)) {
					if (l.getWorld().isChunkLoaded(l.getBlockX() >> 4, l.getBlockZ() >> 4)) {
						final Block b = l.getBlock();
						final SlimefunItem item = BlockStorage.check(l);
						if (item != null) {
							machines++;
							try {
								item.getBlockTicker().update();
								if (item.getBlockTicker().isSynchronized()) {
									Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
										try {
											long timestamp3 = System.currentTimeMillis();
											item.getBlockTicker().tick(b, item, BlockStorage.getLocationInfo(l));

											map_machinetime.put(item.getID(), (map_machinetime.containsKey(item.getID()) ? map_machinetime.get(item.getID()): 0) + (System.currentTimeMillis() - timestamp3));
											map_chunk.put(c, (map_chunk.containsKey(c) ? map_chunk.get(c): 0) + 1);
											map_machine.put(item.getID(), (map_machine.containsKey(item.getID()) ? map_machine.get(item.getID()): 0) + 1);
											block_timings.put(l, System.currentTimeMillis() - timestamp3);
										} catch (Exception x) {
											int errors = 0;
											if (bugged.containsKey(l)) errors = bugged.get(l);
											errors++;

											if (errors == 1) {
												int try_count = 1;
												File file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + ".err");
												while (file.exists()) {
													try_count += 1;
													file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + "(" + try_count + ").err");
												}
												try {
													PrintStream stream = new PrintStream(file);
													stream.println();
													stream.println("Server Software: " + Bukkit.getName());
													stream.println("  Build: " + Bukkit.getVersion());
													stream.println("  Minecraft: " + Bukkit.getBukkitVersion());
													stream.println();
													stream.println("Slimefun Environment:");
													stream.println("  CS-CoreLib v" + CSCoreLib.getLib().getDescription().getVersion());
													stream.println("  Slimefun v" + SlimefunStartup.instance.getDescription().getVersion());
													stream.println();

													List<String> plugins = new ArrayList<>();
													List<String> addons = new ArrayList<>();
													for (Plugin p: Bukkit.getPluginManager().getPlugins()) {
														if (Bukkit.getPluginManager().isPluginEnabled(p)) {
															plugins.add("  + " + p.getName() + " " + p.getDescription().getVersion());
															if (p.getDescription().getDepend().contains("Slimefun") || p.getDescription().getSoftDepend().contains("Slimefun"))
																addons.add("  + " + p.getName() + " " + p.getDescription().getVersion());
														}
														else {
															plugins.add("  - " + p.getName() + " " + p.getDescription().getVersion());
															if (p.getDescription().getDepend().contains("Slimefun") || p.getDescription().getSoftDepend().contains("Slimefun"))
																addons.add("  - " + p.getName() + " " + p.getDescription().getVersion());
														}
													}

													stream.println(" Installed Addons (" + addons.size() + ")");
													for (String addon : addons) {
														stream.println(addon);
													}
													stream.println();
													stream.println("Installed Plugins (" + plugins.size() + "):");
													for (String plugin : plugins) {
														stream.println(plugin);
													}
													stream.println();
													stream.println("Ticked Block:");
													stream.println("  World: " + l.getWorld().getName());
													stream.println("  X: " + l.getBlockX());
													stream.println("  Y: " + l.getBlockY());
													stream.println("  Z: " + l.getBlockZ());
													stream.println();
													stream.println("Slimefun Data:");
													stream.println("  ID: " + item.getID());
													stream.println("  Inventory: " + BlockStorage.getStorage(l.getWorld()).hasInventory(l));
													stream.println("  Data: " + BlockStorage.getBlockInfoAsJson(l));
													stream.println();
													stream.println("Stacktrace:");
													stream.println();
													x.printStackTrace(stream);

													stream.close();
												} catch (FileNotFoundException e) {
													e.printStackTrace();
												}

												System.err.println("[Slimefun] Exception caught while ticking a Block:" + x.getClass().getName());
												System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ());
												System.err.println("[Slimefun] Saved as: ");
												System.err.println("[Slimefun] /plugins/Slimefun/error-reports/" + file.getName());
												System.err.println("[Slimefun] Please consider sending this File to the developer(s) of Slimefun, sending this Error won't get you any help though.");
												System.err.println("[Slimefun] ");

												bugged_blocks.put(l, errors);
											}
											else if (errors == 4) {
												System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ() + "(" + item.getID() + ")");
												System.err.println("[Slimefun] has thrown 4 Exceptions in the last 4 Ticks, the Block has been terminated.");
												System.err.println("[Slimefun] Check your /plugins/Slimefun/error-reports/ folder for details.");
												System.err.println("[Slimefun] ");

												BlockStorage._integrated_removeBlockInfo(l, true);

												Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
													l.getBlock().setType(Material.AIR);
												});
											}
											else {
												bugged_blocks.put(l, errors);
											}
										}
									});
								}
								else {
									long timestamp3 = System.currentTimeMillis();
									item.getBlockTicker().tick(b, item, BlockStorage.getLocationInfo(l));

									map_machinetime.put(item.getID(), (map_machinetime.containsKey(item.getID()) ? map_machinetime.get(item.getID()): 0) + (System.currentTimeMillis() - timestamp3));
									map_chunk.put(c, (map_chunk.containsKey(c) ? map_chunk.get(c): 0) + 1);
									map_machine.put(item.getID(), (map_machine.containsKey(item.getID()) ? map_machine.get(item.getID()): 0) + 1);
									block_timings.put(l, System.currentTimeMillis() - timestamp3);
								}
								tickers.add(item.getBlockTicker());
							} catch (Exception x) {

								int errors = 0;
								if (bugged.containsKey(l)) errors = bugged.get(l);
								errors++;

								if (errors == 1) {
									File file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + ".err");
									if (file.exists()) {
										for (int i = 2; i < 11; i++) {
											file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + " (" + i + ").err");
											if (!file.exists()) break;
										}
									}
									try {
										PrintStream stream = new PrintStream(file);
										stream.println();
										stream.println("Server Software: " + Bukkit.getName());
										stream.println("  Build: " + Bukkit.getVersion());
										stream.println("  Minecraft: " + Bukkit.getBukkitVersion());
										stream.println();
										stream.println("Installed Plugins (" + Bukkit.getPluginManager().getPlugins().length + ")");
										for (Plugin p: Bukkit.getPluginManager().getPlugins()) {
											if (Bukkit.getPluginManager().isPluginEnabled(p)) {
												stream.println("  + " + p.getName() + " " + p.getDescription().getVersion());
											}
											else {
												stream.println("  - " + p.getName() + " " + p.getDescription().getVersion());
											}
										}
										stream.println();
										stream.println("Ticked Block:");
										stream.println("  World: " + l.getWorld().getName());
										stream.println("  X: " + l.getBlockX());
										stream.println("  Y: " + l.getBlockY());
										stream.println("  Z: " + l.getBlockZ());
										stream.println();
										stream.println("Slimefun Data:");
										stream.println("  ID: " + item.getID());
										stream.println("  Inventory: " + BlockStorage.getStorage(l.getWorld()).hasInventory(l));
										stream.println("  Data: " + BlockStorage.getBlockInfoAsJson(l));
										stream.println();
										stream.println("Stacktrace:");
										stream.println();
										x.printStackTrace(stream);

										stream.close();
									} catch (FileNotFoundException e) {
										e.printStackTrace();
									}

									System.err.println("[Slimefun] Exception caught while ticking a Block:" + x.getClass().getName());
									System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ());
									System.err.println("[Slimefun] Saved as: ");
									System.err.println("[Slimefun] /plugins/Slimefun/error-reports/" + file.getName());
									System.err.println("[Slimefun] Please consider sending this File to the developer(s) of Slimefun, sending this Error won't get you any help though.");
									System.err.println("[Slimefun] ");

									bugged_blocks.put(l, errors);
								}
								else if (errors == 4) {
									System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ() + "(" + item.getID() + ")");
									System.err.println("[Slimefun] has thrown 4 Exceptions in the last 4 Ticks, the Block has been terminated.");
									System.err.println("[Slimefun] Check your /plugins/Slimefun/error-reports/ folder for details.");
									System.err.println("[Slimefun] ");

									BlockStorage._integrated_removeBlockInfo(l, true);

									Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
										l.getBlock().setType(Material.AIR);
									});
								}
								else {
									bugged_blocks.put(l, errors);
								}
							}
						}
						else skipped++;
					}
					else {
						skipped += BlockStorage.getTickingLocations(c).size();
						skipped_chunks.add(c);
						chunks--;
						break blocks;
					}
				}

				map_chunktime.put(c, System.currentTimeMillis() - timestamp2);
			}
		}

		for (Map.Entry<Location, Location> entry: move.entrySet()) {
			BlockStorage._integrated_moveLocationInfo(entry.getKey(), entry.getValue());
		}
		move.clear();

		for (BlockTicker ticker: tickers) {
			ticker.unique = true;
		}
		tickers.clear();

		time = System.currentTimeMillis() - timestamp;
	}

	@Override
	public void run() {

		long timestamp = System.currentTimeMillis();

		skipped = 0;
		chunks = 0;
		machines = 0;
		map_chunk.clear();
		map_machine.clear();
		time = 0;
		map_chunktime.clear();
		skipped_chunks.clear();
		map_machinetime.clear();
		block_timings.clear();

		final Map<Location, Integer> bugged = new HashMap<Location, Integer>(bugged_blocks);
		bugged_blocks.clear();

		Map<Location, Boolean> remove = new HashMap<Location, Boolean>(delete);

		for (Map.Entry<Location, Boolean> entry: remove.entrySet()) {
			BlockStorage._integrated_removeBlockInfo(entry.getKey(), entry.getValue());
			delete.remove(entry.getKey());
		}

		if (!HALTED) {
			for (final String c: BlockStorage.getTickingChunks()) {
				long timestamp2 = System.currentTimeMillis();
				chunks++;

				blocks:
				for (final Location l: BlockStorage.getTickingLocations(c)) {
					if (l.getWorld().isChunkLoaded(l.getBlockX() >> 4, l.getBlockZ() >> 4)) {
						final Block b = l.getBlock();
						final SlimefunItem item = BlockStorage.check(l);
						if (item != null) {
							machines++;
							try {
								item.getBlockTicker().update();
								if (item.getBlockTicker().isSynchronized()) {
									Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

										@Override
										public void run() {
											try {
												long timestamp3 = System.currentTimeMillis();
												item.getBlockTicker().tick(b, item, BlockStorage.getLocationInfo(l));

												map_machinetime.put(item.getID(), (map_machinetime.containsKey(item.getID()) ? map_machinetime.get(item.getID()): 0) + (System.currentTimeMillis() - timestamp3));
												map_chunk.put(c, (map_chunk.containsKey(c) ? map_chunk.get(c): 0) + 1);
												map_machine.put(item.getID(), (map_machine.containsKey(item.getID()) ? map_machine.get(item.getID()): 0) + 1);
												block_timings.put(l, System.currentTimeMillis() - timestamp3);
											} catch (Exception x) {
												int errors = 0;
												if (bugged.containsKey(l)) errors = bugged.get(l);
												errors++;

												if (errors == 1) {
													int try_count = 1;
													File file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + ".err");
													while (file.exists()) {
														try_count += 1;
														file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + "(" + try_count + ").err");
													}
													try {
														PrintStream stream = new PrintStream(file);
														stream.println();
														stream.println("Server Software: " + Bukkit.getName());
														stream.println("  Build: " + Bukkit.getVersion());
														stream.println("  Minecraft: " + Bukkit.getBukkitVersion());
														stream.println();
														stream.println("Slimefun Environment:");
														stream.println("  CS-CoreLib v" + CSCoreLib.getLib().getDescription().getVersion());
														stream.println("  Slimefun v" + SlimefunStartup.instance.getDescription().getVersion());
														stream.println();

														List<String> plugins = new ArrayList<>();
														List<String> addons = new ArrayList<>();
														for (Plugin p: Bukkit.getPluginManager().getPlugins()) {
															if (Bukkit.getPluginManager().isPluginEnabled(p)) {
																plugins.add("  + " + p.getName() + " " + p.getDescription().getVersion());
																if (p.getDescription().getDepend().contains("Slimefun") || p.getDescription().getSoftDepend().contains("Slimefun"))
																	addons.add("  + " + p.getName() + " " + p.getDescription().getVersion());
															}
															else {
																plugins.add("  - " + p.getName() + " " + p.getDescription().getVersion());
																if (p.getDescription().getDepend().contains("Slimefun") || p.getDescription().getSoftDepend().contains("Slimefun"))
																	addons.add("  - " + p.getName() + " " + p.getDescription().getVersion());
															}
														}

														stream.println(" Installed Addons (" + addons.size() + ")");
														for (String addon : addons) {
															stream.println(addon);
														}
														stream.println();
														stream.println("Installed Plugins (" + plugins.size() + "):");
														for (String plugin : plugins) {
															stream.println(plugin);
														}
														stream.println();
														stream.println("Ticked Block:");
														stream.println("  World: " + l.getWorld().getName());
														stream.println("  X: " + l.getBlockX());
														stream.println("  Y: " + l.getBlockY());
														stream.println("  Z: " + l.getBlockZ());
														stream.println();
														stream.println("Slimefun Data:");
														stream.println("  ID: " + item.getID());
														stream.println("  Inventory: " + BlockStorage.getStorage(l.getWorld()).hasInventory(l));
														stream.println("  Data: " + BlockStorage.getBlockInfoAsJson(l));
														stream.println();
														stream.println("Stacktrace:");
														stream.println();
														x.printStackTrace(stream);

														stream.close();
													} catch (FileNotFoundException e) {
														e.printStackTrace();
													}

													System.err.println("[Slimefun] Exception caught while ticking a Block:" + x.getClass().getName());
													System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ());
													System.err.println("[Slimefun] Saved as: ");
													System.err.println("[Slimefun] /plugins/Slimefun/error-reports/" + file.getName());
													System.err.println("[Slimefun] Please consider sending this File to the developer(s) of Slimefun, sending this Error won't get you any help though.");
													System.err.println("[Slimefun] ");

													bugged_blocks.put(l, errors);
												}
												else if (errors == 4) {
													System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ() + "(" + item.getID() + ")");
													System.err.println("[Slimefun] has thrown 4 Exceptions in the last 4 Ticks, the Block has been terminated.");
													System.err.println("[Slimefun] Check your /plugins/Slimefun/error-reports/ folder for details.");
													System.err.println("[Slimefun] ");

													BlockStorage._integrated_removeBlockInfo(l, true);

													Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

														@Override
														public void run() {
															l.getBlock().setType(Material.AIR);
														}

													});
												}
												else {
													bugged_blocks.put(l, errors);
												}
											}
										}
									});
								}
								else {
									long timestamp3 = System.currentTimeMillis();
									item.getBlockTicker().tick(b, item, BlockStorage.getLocationInfo(l));

									map_machinetime.put(item.getID(), (map_machinetime.containsKey(item.getID()) ? map_machinetime.get(item.getID()): 0) + (System.currentTimeMillis() - timestamp3));
									map_chunk.put(c, (map_chunk.containsKey(c) ? map_chunk.get(c): 0) + 1);
									map_machine.put(item.getID(), (map_machine.containsKey(item.getID()) ? map_machine.get(item.getID()): 0) + 1);
									block_timings.put(l, System.currentTimeMillis() - timestamp3);
								}
								tickers.add(item.getBlockTicker());
							} catch (Exception x) {

								int errors = 0;
								if (bugged.containsKey(l)) errors = bugged.get(l);
								errors++;

								if (errors == 1) {
									File file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + ".err");
									if (file.exists()) {
										for (int i = 2; i < 11; i++) {
											file = new File("plugins/Slimefun/error-reports/" + Clock.getFormattedTime() + " (" + i + ").err");
											if (!file.exists()) break;
										}
									}
									try {
										PrintStream stream = new PrintStream(file);
										stream.println();
										stream.println("Server Software: " + Bukkit.getName());
										stream.println("  Build: " + Bukkit.getVersion());
										stream.println("  Minecraft: " + Bukkit.getBukkitVersion());
										stream.println();
										stream.println("Installed Plugins (" + Bukkit.getPluginManager().getPlugins().length + ")");
										for (Plugin p: Bukkit.getPluginManager().getPlugins()) {
											if (Bukkit.getPluginManager().isPluginEnabled(p)) {
												stream.println("  + " + p.getName() + " " + p.getDescription().getVersion());
											}
											else {
												stream.println("  - " + p.getName() + " " + p.getDescription().getVersion());
											}
										}
										stream.println();
										stream.println("Ticked Block:");
										stream.println("  World: " + l.getWorld().getName());
										stream.println("  X: " + l.getBlockX());
										stream.println("  Y: " + l.getBlockY());
										stream.println("  Z: " + l.getBlockZ());
										stream.println();
										stream.println("Slimefun Data:");
										stream.println("  ID: " + item.getID());
										stream.println("  Inventory: " + BlockStorage.getStorage(l.getWorld()).hasInventory(l));
										stream.println("  Data: " + BlockStorage.getBlockInfoAsJson(l));
										stream.println();
										stream.println("Stacktrace:");
										stream.println();
										x.printStackTrace(stream);

										stream.close();
									} catch (FileNotFoundException e) {
										e.printStackTrace();
									}

									System.err.println("[Slimefun] Exception caught while ticking a Block:" + x.getClass().getName());
									System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ());
									System.err.println("[Slimefun] Saved as: ");
									System.err.println("[Slimefun] /plugins/Slimefun/error-reports/" + file.getName());
									System.err.println("[Slimefun] Please consider sending this File to the developer(s) of Slimefun, sending this Error won't get you any help though.");
									System.err.println("[Slimefun] ");

									bugged_blocks.put(l, errors);
								}
								else if (errors == 4) {
									System.err.println("[Slimefun] X: " + l.getBlockX() + " Y: " + l.getBlockY() + " Z: " + l.getBlockZ() + "(" + item.getID() + ")");
									System.err.println("[Slimefun] has thrown 4 Exceptions in the last 4 Ticks, the Block has been terminated.");
									System.err.println("[Slimefun] Check your /plugins/Slimefun/error-reports/ folder for details.");
									System.err.println("[Slimefun] ");

									BlockStorage._integrated_removeBlockInfo(l, true);

									Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

										@Override
										public void run() {
											l.getBlock().setType(Material.AIR);
										}

									});
								}
								else {
									bugged_blocks.put(l, errors);
								}
							}
						}
						else skipped++;
					}
					else {
						skipped += BlockStorage.getTickingLocations(c).size();
						skipped_chunks.add(c);
						chunks--;
						break blocks;
					}
				}

				map_chunktime.put(c, System.currentTimeMillis() - timestamp2);
			}
		}

		for (Map.Entry<Location, Location> entry: move.entrySet()) {
			BlockStorage._integrated_moveLocationInfo(entry.getKey(), entry.getValue());
		}
		move.clear();

		for (BlockTicker ticker: tickers) {
			ticker.unique = true;
		}
		tickers.clear();

		time = System.currentTimeMillis() - timestamp;
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.api.TickerTask.run.scheduleSyncDelayedTask.new Runnable with () -> {trylong timestamp3=System.currentTimeMillis(); in method public run() : void from class me.mrCookieSlime.Slimefun.api.TickerTask


	private static void updateTexture(final Location l) throws Exception {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
			try {
				Block b = l.getBlock();
				int charge = getCharge(b), capacity = getMaxCharge(b);
				if (b.getState() instanceof Skull) {
					if (charge < (int) (capacity * 0.25D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTEzNjFlNTc2YjQ5M2NiZmRmYWUzMjg2NjFjZWRkMWFkZDU1ZmFiNGU1ZWI0MThiOTJjZWJmNjI3NWY4YmI0In19fQ==");
					else if (charge < (int) (capacity * 0.5D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMzA1MzIzMzk0YTdkOTFiZmIzM2RmMDZkOTJiNjNjYjQxNGVmODBmMDU0ZDA0NzM0ZWEwMTVhMjNjNTM5In19fQ==");
					else if (charge < (int) (capacity * 0.75D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNTU4NDQzMmFmNmYzODIxNjcxMjAyNThkMWVlZThjODdjNmU3NWQ5ZTQ3OWU3YjBkNGM3YjZhZDQ4Y2ZlZWYifX19");
					else CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvN2EyNTY5NDE1YzE0ZTMxYzk4ZWM5OTNhMmY5OWU2ZDY0ODQ2ZGIzNjdhMTNiMTk5OTY1YWQ5OWM0MzhjODZjIn19fQ==");
				}
			} catch (Exception e) {
				e.printStackTrace();
			}
		});
	}

	private static void updateTexture(final Location l) throws Exception {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

			@Override
			public void run() {
				try {
					Block b = l.getBlock();
					int charge = getCharge(b), capacity = getMaxCharge(b);
					if (b.getState() instanceof Skull) {
						if (charge < (int) (capacity * 0.25D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvOTEzNjFlNTc2YjQ5M2NiZmRmYWUzMjg2NjFjZWRkMWFkZDU1ZmFiNGU1ZWI0MThiOTJjZWJmNjI3NWY4YmI0In19fQ==");
						else if (charge < (int) (capacity * 0.5D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvMzA1MzIzMzk0YTdkOTFiZmIzM2RmMDZkOTJiNjNjYjQxNGVmODBmMDU0ZDA0NzM0ZWEwMTVhMjNjNTM5In19fQ==");
						else if (charge < (int) (capacity * 0.75D)) CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvNTU4NDQzMmFmNmYzODIxNjcxMjAyNThkMWVlZThjODdjNmU3NWQ5ZTQ3OWU3YjBkNGM3YjZhZDQ4Y2ZlZWYifX19");
						else CustomSkull.setSkull(b, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvN2EyNTY5NDE1YzE0ZTMxYzk4ZWM5OTNhMmY5OWU2ZDY0ODQ2ZGIzNjdhMTNiMTk5OTY1YWQ5OWM0MzhjODZjIn19fQ==");
					}
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.api.energy.ChargableBlock.updateTexture.scheduleSyncDelayedTask.new Runnable with () -> {tryBlock b=l.getBlock(); in method private updateTexture(l Location) : void from class me.mrCookieSlime.Slimefun.api.energy.ChargableBlock


	public void tick(Block b) {
		if (!regulator.equals(b.getLocation())) {
			EnergyHologram.update(b, "&4Multiple Energy Regulators connected");
			return;
		}
		super.tick();
		double supply = 0.0D;
		double demand = 0.0D;

		if (connectorNodes.isEmpty() && terminusNodes.isEmpty()) {
			EnergyHologram.update(b, "&4No Energy Network found");
		}
		else {
			for (final Location source: input) {
				long timestamp = System.currentTimeMillis();
				SlimefunItem item = BlockStorage.check(source);
				double energy = item.getEnergyTicker().generateEnergy(source, item, BlockStorage.getLocationInfo(source));

				if (item.getEnergyTicker().explode(source)) {
					BlockStorage.clearBlockInfo(source);
					Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
						source.getBlock().setType(Material.LAVA);
						source.getWorld().createExplosion(source, 0F, false);
					});
				}
				else {
					supply = supply + energy;
				}
				TickerTask.block_timings.put(source, System.currentTimeMillis() - timestamp);
			}

			for (Location battery: storage) {
				supply = supply + ChargableBlock.getCharge(battery);
			}

			int available = (int) DoubleHandler.fixDouble(supply);

			for (Location destination: output) {
				int capacity = ChargableBlock.getMaxCharge(destination);
				int charge = ChargableBlock.getCharge(destination);
				if (charge < capacity) {
					int rest = capacity - charge;
					demand = demand + rest;
					if (available > 0) {
						if (available > rest) {
							ChargableBlock.setUnsafeCharge(destination, capacity, false);
							available = available - rest;
						}
						else {
							ChargableBlock.setUnsafeCharge(destination, charge + available, false);
							available = 0;
						}
					}
				}
			}

			for (Location battery: storage) {
				if (available > 0) {
					int capacity = ChargableBlock.getMaxCharge(battery);

					if (available > capacity) {
						ChargableBlock.setUnsafeCharge(battery, capacity, true);
						available = available - capacity;
					}
					else {
						ChargableBlock.setUnsafeCharge(battery, available, true);
						available = 0;
					}
				}
				else ChargableBlock.setUnsafeCharge(battery, 0, true);
			}

			for (Location source: input) {
				if (ChargableBlock.isChargable(source)) {
					if (available > 0) {
						int capacity = ChargableBlock.getMaxCharge(source);

						if (available > capacity) {
							ChargableBlock.setUnsafeCharge(source, capacity, false);
							available = available - capacity;
						}
						else {
							ChargableBlock.setUnsafeCharge(source, available, false);
							available = 0;
						}
					}
					else ChargableBlock.setUnsafeCharge(source, 0, false);
				}
			}

			EnergyHologram.update(b, supply, demand);
		}
	}

	public void tick(Block b) {
		if (!regulator.equals(b.getLocation())) {
			EnergyHologram.update(b, "&4Multiple Energy Regulators connected");
			return;
		}
		super.tick();
		double supply = 0.0D;
		double demand = 0.0D;

		if (connectorNodes.isEmpty() && terminusNodes.isEmpty()) {
			EnergyHologram.update(b, "&4No Energy Network found");
		}
		else {
			for (final Location source: input) {
				long timestamp = System.currentTimeMillis();
				SlimefunItem item = BlockStorage.check(source);
				double energy = item.getEnergyTicker().generateEnergy(source, item, BlockStorage.getLocationInfo(source));

				if (item.getEnergyTicker().explode(source)) {
					BlockStorage.clearBlockInfo(source);
					Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

						@Override
						public void run() {
							source.getBlock().setType(Material.LAVA);
							source.getWorld().createExplosion(source, 0F, false);
						}
					});
				}
				else {
					supply = supply + energy;
				}
				TickerTask.block_timings.put(source, System.currentTimeMillis() - timestamp);
			}

			for (Location battery: storage) {
				supply = supply + ChargableBlock.getCharge(battery);
			}

			int available = (int) DoubleHandler.fixDouble(supply);

			for (Location destination: output) {
				int capacity = ChargableBlock.getMaxCharge(destination);
				int charge = ChargableBlock.getCharge(destination);
				if (charge < capacity) {
					int rest = capacity - charge;
					demand = demand + rest;
					if (available > 0) {
						if (available > rest) {
							ChargableBlock.setUnsafeCharge(destination, capacity, false);
							available = available - rest;
						}
						else {
							ChargableBlock.setUnsafeCharge(destination, charge + available, false);
							available = 0;
						}
					}
				}
			}

			for (Location battery: storage) {
				if (available > 0) {
					int capacity = ChargableBlock.getMaxCharge(battery);

					if (available > capacity) {
						ChargableBlock.setUnsafeCharge(battery, capacity, true);
						available = available - capacity;
					}
					else {
						ChargableBlock.setUnsafeCharge(battery, available, true);
						available = 0;
					}
				}
				else ChargableBlock.setUnsafeCharge(battery, 0, true);
			}

			for (Location source: input) {
				if (ChargableBlock.isChargable(source)) {
					if (available > 0) {
						int capacity = ChargableBlock.getMaxCharge(source);

						if (available > capacity) {
							ChargableBlock.setUnsafeCharge(source, capacity, false);
							available = available - capacity;
						}
						else {
							ChargableBlock.setUnsafeCharge(source, available, false);
							available = 0;
						}
					}
					else ChargableBlock.setUnsafeCharge(source, 0, false);
				}
			}

			EnergyHologram.update(b, supply, demand);
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.api.energy.EnergyNet.tick.scheduleSyncDelayedTask.new Runnable with () -> {source.getBlock().setType(Material.LAVA); in method public tick(b Block) : void from class me.mrCookieSlime.Slimefun.api.energy.EnergyNet


	public void newInstance(final BlockMenu menu, final Location l) {
		Bukkit.getScheduler().runTask(SlimefunStartup.instance, () -> {
			newInstance(menu, l.getBlock());
		});
	}

	public void newInstance(final BlockMenu menu, final Location l) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {
			public void run() {
				newInstance(menu, l.getBlock());
			}
		});
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.api.inventory.BlockMenuPreset.newInstance.scheduleSyncDelayedTask.new Runnable with () -> {newInstance(menu,l.getBlock()); in method public newInstance(menu BlockMenu, l Location) : void from class me.mrCookieSlime.Slimefun.api.inventory.BlockMenuPreset


	public void tick(final Block b) {
		if (!regulator.equals(b.getLocation())) {
			CargoHologram.update(b, "&4Multiple Cargo Regulators connected");
			return;
		}
		super.tick();
		if (connectorNodes.isEmpty() && terminusNodes.isEmpty()) {
			CargoHologram.update(b, "&7Status: &4&lOFFLINE");
			return;
		}
		else {
			CargoHologram.update(b, "&7Status: &a&lONLINE");

			final Map<Integer, List<Location>> output = new HashMap<Integer, List<Location>>();

			for (Location outputNode: outputNodes) {
				Integer frequency = getFrequency(outputNode);
				if (!output.containsKey(frequency)) {
					output.put(frequency, new ArrayList<Location>());
				}
				output.get(frequency).add(outputNode);
			}
			for (Location outputNode: advancedOutputNodes) {
				Integer frequency = getFrequency(outputNode);
				if (!output.containsKey(frequency)) {
					output.put(frequency, new ArrayList<Location>());
				}
				output.get(frequency).add(outputNode);
			}

			//Chest Terminal Stuff
			final Set<Location> providers = new HashSet<Location>();
			final Set<Location> destinations;
			if (output.containsKey(16)) {
				destinations = new HashSet<Location>(output.get(16));
			} else {
				destinations = new HashSet<Location>();
			}
			for (Location inputNode: inputNodes) {
				int frequency = getFrequency(inputNode);
				if (frequency == 16) {
					providers.add(inputNode);
				}
			}

			CargoNet self = this;
			final BlockStorage storage = BlockStorage.getStorage(b.getWorld());
			SlimefunStartup.instance.getServer().getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
				if (BlockStorage.getLocationInfo(b.getLocation(), "visualizer") == null) {
					self.display();
				}
				//Chest Terminal Code
				if (EXTRA_CHANNELS) {
					for (Location bus: imports) {
						BlockMenu menu = BlockStorage.getInventory(bus);

						if (menu.getItemInSlot(17) == null) {
							Block target = getAttachedBlock(bus.getBlock());
							ItemSlot stack = CargoManager.withdraw(bus.getBlock(), storage, target, -1);

							if (stack != null) {
								menu.replaceExistingItem(17, stack.getItem());
							}
						}

						if (menu.getItemInSlot(17) != null) {
							requests.add(new ItemRequest(bus, 17, menu.getItemInSlot(17), ItemTransportFlow.INSERT));
						}
					}

					for (Location bus: exports) {
						BlockMenu menu = BlockStorage.getInventory(bus);

						if (menu.getItemInSlot(17) != null) {
							Block target = getAttachedBlock(bus.getBlock());

							menu.replaceExistingItem(17, CargoManager.insert(bus.getBlock(), storage, target, menu.getItemInSlot(17), -1));
						}

						if (menu.getItemInSlot(17) == null) {
							List<ItemStack> items = new ArrayList<ItemStack>();
							for (int slot: slots) {
								ItemStack template = menu.getItemInSlot(slot);
								if (template != null) items.add(new CustomItem(template, 1));
							}

							if (!items.isEmpty()) {
								int index = Integer.parseInt(BlockStorage.getLocationInfo(bus, "index"));

								index++;
								if (index > (items.size() - 1)) index = 0;

								BlockStorage.addBlockInfo(bus, "index", String.valueOf(index));

								requests.add(new ItemRequest(bus, 17, items.get(index), ItemTransportFlow.WITHDRAW));
							}
						}
					}

					Iterator<ItemRequest> iterator = requests.iterator();
					while (iterator.hasNext()) {
						ItemRequest request = iterator.next();
						if (terminals.contains(request.getTerminal()) || imports.contains(request.getTerminal()) || exports.contains(request.getTerminal())) {
							BlockMenu menu = BlockStorage.getInventory(request.getTerminal());

							switch (request.getDirection()) {
							case INSERT: {
								ItemStack stack = request.getItem();
								nodes:
								for (Location l: destinations) {
									Block target = getAttachedBlock(l.getBlock());
									stack = CargoManager.insert(l.getBlock(), storage, target, stack, -1);
									if (stack == null) {
										menu.replaceExistingItem(request.getSlot(), null);
										break nodes;
									}
								}

								if (stack != null) {
									menu.replaceExistingItem(request.getSlot(), stack);
								}

								iterator.remove();
								break;
							}
							case WITHDRAW: {
								int slot = request.getSlot();
								ItemStack prevStack = menu.getItemInSlot(slot);
								if (!(prevStack == null || (prevStack.getAmount() + request.getItem().getAmount() <= prevStack.getMaxStackSize() && SlimefunManager.isItemSimiliar(prevStack, new CustomItem(request.getItem(), 1), true, DataType.ALWAYS)))) {
									iterator.remove();
									break;
								}

								ItemStack stack = null;
								ItemStack requested = request.getItem();
								nodes:
								for (Location l: providers) {
									Block target = getAttachedBlock(l.getBlock());
									ItemStack is = CargoManager.withdraw(l.getBlock(), storage, target, requested);
									if (is != null) {
										if (stack == null) {
											stack = is;
										}
										else {
											stack = new CustomItem(stack, stack.getAmount() + is.getAmount());
										}

										if (is.getAmount() == requested.getAmount()) {
											break nodes;
										}
										else {
											requested = new CustomItem(requested, requested.getAmount() - is.getAmount());
										}
									}
								}

								if (stack != null) {
									ItemStack prev = menu.getItemInSlot(slot);

									if (prev == null) menu.replaceExistingItem(slot, stack);
									else menu.replaceExistingItem(slot, new CustomItem(stack, stack.getAmount() + prev.getAmount()));
								}

								iterator.remove();
								break;
							}
							default: {
								break;
							}
							}
						}
					}
				}
				// All operations happen here: Everything gets iterated from the Input Nodes. (Apart from ChestTerminal Buses)
				for (Location input: inputNodes) {
					Integer frequency = getFrequency(input);
					if (frequency < 0 || frequency > 15) {
						continue;
					}
					Block inputTarget = getAttachedBlock(input.getBlock());
					ItemStack stack = null;
					int previousSlot = -1;

					boolean roundrobin = BlockStorage.getLocationInfo(input, "round-robin").equals("true");

					if (inputTarget != null) {
						ItemSlot slot = CargoManager.withdraw(input.getBlock(), storage, inputTarget, Integer.parseInt(BlockStorage.getLocationInfo(input, "index")));
						if (slot != null) {
							stack = slot.getItem();
							previousSlot = slot.getSlot();
						}
					}

					if (stack != null && output.containsKey(frequency)) {
						List<Location> outputlist = new ArrayList<Location>(output.get(frequency));

						if (roundrobin) {
							if (!round_robin.containsKey(input)) {
								round_robin.put(input, 0);
							}

							int c_index = round_robin.get(input);

							if (c_index < outputlist.size()) {
								for (int i = 0; i < c_index; i++) {
									final Location temp = outputlist.get(0);
									outputlist.remove(temp);
									outputlist.add(temp);
								}
								c_index++;
							}
							else c_index = 1;

							round_robin.put(input, c_index);
						}

						destinations:
						for (Location out: outputlist) {
							Block target = getAttachedBlock(out.getBlock());
							if (target != null) {
								stack = CargoManager.insert(out.getBlock(), storage, target, stack, -1);
								if (stack == null) break destinations;
							}
						}
					}

					if (stack != null && previousSlot > -1) {
						if (storage.hasUniversalInventory(inputTarget)) {
							UniversalBlockMenu menu = storage.getUniversalInventory(inputTarget);
							menu.replaceExistingItem(previousSlot, stack);
						}
						else if (storage.hasInventory(inputTarget.getLocation())) {
							BlockMenu menu = BlockStorage.getInventory(inputTarget.getLocation());
							menu.replaceExistingItem(previousSlot, stack);
						}
						else if (inputTarget.getState() instanceof InventoryHolder) {
							Inventory inv = ((InventoryHolder) inputTarget.getState()).getInventory();
							inv.setItem(previousSlot, stack);
						}
					}
				}
				//Chest Terminal Code
				if (EXTRA_CHANNELS) {
					List<StoredItem> items = new ArrayList<StoredItem>();
					for (Location l: providers) {
						Block target = getAttachedBlock(l.getBlock());
						if (storage.hasUniversalInventory(target)) {
							UniversalBlockMenu menu = storage.getUniversalInventory(target);
							for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
								ItemStack is = menu.getItemInSlot(slot);
								if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
									boolean add = true;
									for (StoredItem item: items) {
										if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
											add = false;
											item.add(is.getAmount());
										}
									}

									if (add) {
										items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
									}
								}
							}
						}
						else if (storage.hasInventory(target.getLocation())) {
							BlockMenu menu = BlockStorage.getInventory(target.getLocation());
							if (BlockStorage.checkID(target.getLocation()).startsWith("BARREL_") && BlockStorage.getLocationInfo(target.getLocation(), "storedItems") != null) {
								int stored = Integer.valueOf(BlockStorage.getLocationInfo(target.getLocation(), "storedItems"));
								for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
									ItemStack is = menu.getItemInSlot(slot);
									if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
										boolean add = true;
										for (StoredItem item: items) {
											if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
												add = false;
												item.add(is.getAmount() + stored);
											}
										}

										if (add) {
											items.add(new StoredItem(new CustomItem(is, 1), is.getAmount() + stored));
										}
									}
								}
							}
							else {
								for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
									ItemStack is = menu.getItemInSlot(slot);
									if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
										boolean add = true;
										for (StoredItem item: items) {
											if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
												add = false;
												item.add(is.getAmount());
											}
										}

										if (add) {
											items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
										}
									}
								}
							}
						}
						else if (target.getState() instanceof InventoryHolder) {
							Inventory inv = ((InventoryHolder) target.getState()).getInventory();
							for (ItemStack is: inv.getContents()) {
								if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
									boolean add = true;
									for (StoredItem item: items) {
										if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
											add = false;
											item.add(is.getAmount());
										}
									}

									if (add) {
										items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
									}
								}
							}
						}
					}

					Collections.sort(items, sorter);

					for (final Location l: terminals) {
						BlockMenu menu = BlockStorage.getInventory(l);
						int page = Integer.parseInt(BlockStorage.getLocationInfo(l, "page"));
						if (!items.isEmpty() && items.size() < (page - 1) * terminal_slots.length + 1) {
							page = 1;
							BlockStorage.addBlockInfo(l, "page", String.valueOf(1));
						}

						for (int i = 0; i < terminal_slots.length; i++) {
							int slot = terminal_slots[i];
							if (items.size() > i + (terminal_slots.length * (page - 1))) {
								final StoredItem item = items.get(i + (terminal_slots.length * (page - 1)));

								ItemStack stack = item.getItem().clone();
								ItemMeta im = stack.getItemMeta();
								List<String> lore = new ArrayList<String>();
								lore.add("");
								lore.add(ChatColor.translateAlternateColorCodes('&', "&7Stored Items: &r" + DoubleHandler.getFancyDouble(item.getAmount())));
								if (stack.getMaxStackSize() > 1) lore.add(ChatColor.translateAlternateColorCodes('&', "&7<Left Click: Request 1 | Right Click: Request " + (item.getAmount() > stack.getMaxStackSize() ? stack.getMaxStackSize(): item.getAmount()) + ">"));
								else lore.add(ChatColor.translateAlternateColorCodes('&', "&7<Left Click: Request 1>"));
								lore.add("");
								if (im.hasLore()) {
									for (String line: im.getLore()) {
										lore.add(line);
									}
								}
								im.setLore(lore);
								stack.setItemMeta(im);
								menu.replaceExistingItem(slot, stack);
								menu.addMenuClickHandler(slot, new MenuClickHandler() {

									@Override
									public boolean onClick(Player p, int slot, ItemStack is, ClickAction action) {
										requests.add(new ItemRequest(l, 44, new CustomItem(item.getItem(), action.isRightClicked() ? (item.getAmount() > item.getItem().getMaxStackSize() ? item.getItem().getMaxStackSize(): item.getAmount()): 1), ItemTransportFlow.WITHDRAW));
										return false;
									}
								});

							}
							else {
								menu.replaceExistingItem(slot, terminal_noitem_item);
								menu.addMenuClickHandler(slot, terminal_noitem_handler);
							}
						}

						ItemStack sent_item = menu.getItemInSlot(17);
						if (sent_item != null) {
							requests.add(new ItemRequest(l, 17, sent_item, ItemTransportFlow.INSERT));
						}
					}
				}
			});
		}
	}

	public void tick(final Block b) {
		if (!regulator.equals(b.getLocation())) {
			CargoHologram.update(b, "&4Multiple Cargo Regulators connected");
			return;
		}
		super.tick();
		if (connectorNodes.isEmpty() && terminusNodes.isEmpty()) {
			CargoHologram.update(b, "&7Status: &4&lOFFLINE");
			return;
		}
		else {
			CargoHologram.update(b, "&7Status: &a&lONLINE");

			final Map<Integer, List<Location>> output = new HashMap<Integer, List<Location>>();

			for (Location outputNode: outputNodes) {
				Integer frequency = getFrequency(outputNode);
				if (!output.containsKey(frequency)) {
					output.put(frequency, new ArrayList<Location>());
				}
				output.get(frequency).add(outputNode);
			}
			for (Location outputNode: advancedOutputNodes) {
				Integer frequency = getFrequency(outputNode);
				if (!output.containsKey(frequency)) {
					output.put(frequency, new ArrayList<Location>());
				}
				output.get(frequency).add(outputNode);
			}

			//Chest Terminal Stuff
			final Set<Location> providers = new HashSet<Location>();
			final Set<Location> destinations;
			if (output.containsKey(16)) {
				destinations = new HashSet<Location>(output.get(16));
			} else {
				destinations = new HashSet<Location>();
			}
			for (Location inputNode: inputNodes) {
				int frequency = getFrequency(inputNode);
				if (frequency == 16) {
					providers.add(inputNode);
				}
			}

			CargoNet self = this;
			final BlockStorage storage = BlockStorage.getStorage(b.getWorld());
			SlimefunStartup.instance.getServer().getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

				@Override
				public void run() {
					if (BlockStorage.getLocationInfo(b.getLocation(), "visualizer") == null) {
						self.display();
					}
					//Chest Terminal Code
					if (EXTRA_CHANNELS) {
						for (Location bus: imports) {
							BlockMenu menu = BlockStorage.getInventory(bus);

							if (menu.getItemInSlot(17) == null) {
								Block target = getAttachedBlock(bus.getBlock());
								ItemSlot stack = CargoManager.withdraw(bus.getBlock(), storage, target, -1);

								if (stack != null) {
									menu.replaceExistingItem(17, stack.getItem());
								}
							}

							if (menu.getItemInSlot(17) != null) {
								requests.add(new ItemRequest(bus, 17, menu.getItemInSlot(17), ItemTransportFlow.INSERT));
							}
						}

						for (Location bus: exports) {
							BlockMenu menu = BlockStorage.getInventory(bus);

							if (menu.getItemInSlot(17) != null) {
								Block target = getAttachedBlock(bus.getBlock());

								menu.replaceExistingItem(17, CargoManager.insert(bus.getBlock(), storage, target, menu.getItemInSlot(17), -1));
							}

							if (menu.getItemInSlot(17) == null) {
								List<ItemStack> items = new ArrayList<ItemStack>();
								for (int slot: slots) {
									ItemStack template = menu.getItemInSlot(slot);
									if (template != null) items.add(new CustomItem(template, 1));
								}

								if (!items.isEmpty()) {
									int index = Integer.parseInt(BlockStorage.getLocationInfo(bus, "index"));

									index++;
									if (index > (items.size() - 1)) index = 0;

									BlockStorage.addBlockInfo(bus, "index", String.valueOf(index));

									requests.add(new ItemRequest(bus, 17, items.get(index), ItemTransportFlow.WITHDRAW));
								}
							}
						}

						Iterator<ItemRequest> iterator = requests.iterator();
						while (iterator.hasNext()) {
							ItemRequest request = iterator.next();
							if (terminals.contains(request.getTerminal()) || imports.contains(request.getTerminal()) || exports.contains(request.getTerminal())) {
								BlockMenu menu = BlockStorage.getInventory(request.getTerminal());

								switch (request.getDirection()) {
								case INSERT: {
									ItemStack stack = request.getItem();
									nodes:
									for (Location l: destinations) {
										Block target = getAttachedBlock(l.getBlock());
										stack = CargoManager.insert(l.getBlock(), storage, target, stack, -1);
										if (stack == null) {
											menu.replaceExistingItem(request.getSlot(), null);
											break nodes;
										}
									}

									if (stack != null) {
										menu.replaceExistingItem(request.getSlot(), stack);
									}

									iterator.remove();
									break;
								}
								case WITHDRAW: {
									int slot = request.getSlot();
									ItemStack prevStack = menu.getItemInSlot(slot);
									if (!(prevStack == null || (prevStack.getAmount() + request.getItem().getAmount() <= prevStack.getMaxStackSize() && SlimefunManager.isItemSimiliar(prevStack, new CustomItem(request.getItem(), 1), true, DataType.ALWAYS)))) {
										iterator.remove();
										break;
									}

									ItemStack stack = null;
									ItemStack requested = request.getItem();
									nodes:
									for (Location l: providers) {
										Block target = getAttachedBlock(l.getBlock());
										ItemStack is = CargoManager.withdraw(l.getBlock(), storage, target, requested);
										if (is != null) {
											if (stack == null) {
												stack = is;
											}
											else {
												stack = new CustomItem(stack, stack.getAmount() + is.getAmount());
											}

											if (is.getAmount() == requested.getAmount()) {
												break nodes;
											}
											else {
												requested = new CustomItem(requested, requested.getAmount() - is.getAmount());
											}
										}
									}

									if (stack != null) {
										ItemStack prev = menu.getItemInSlot(slot);

										if (prev == null) menu.replaceExistingItem(slot, stack);
										else menu.replaceExistingItem(slot, new CustomItem(stack, stack.getAmount() + prev.getAmount()));
									}

									iterator.remove();
									break;
								}
								default: {
									break;
								}
								}
							}
						}
					}
					// All operations happen here: Everything gets iterated from the Input Nodes. (Apart from ChestTerminal Buses)
					for (Location input: inputNodes) {
						Integer frequency = getFrequency(input);
						if (frequency < 0 || frequency > 15) {
							continue;
						}
						Block inputTarget = getAttachedBlock(input.getBlock());
						ItemStack stack = null;
						int previousSlot = -1;

						boolean roundrobin = BlockStorage.getLocationInfo(input, "round-robin").equals("true");

						if (inputTarget != null) {
							ItemSlot slot = CargoManager.withdraw(input.getBlock(), storage, inputTarget, Integer.parseInt(BlockStorage.getLocationInfo(input, "index")));
							if (slot != null) {
								stack = slot.getItem();
								previousSlot = slot.getSlot();
							}
						}

						if (stack != null && output.containsKey(frequency)) {
							List<Location> outputlist = new ArrayList<Location>(output.get(frequency));

							if (roundrobin) {
								if (!round_robin.containsKey(input)) {
									round_robin.put(input, 0);
								}

								int c_index = round_robin.get(input);

								if (c_index < outputlist.size()) {
									for (int i = 0; i < c_index; i++) {
										final Location temp = outputlist.get(0);
										outputlist.remove(temp);
										outputlist.add(temp);
									}
									c_index++;
								}
								else c_index = 1;

								round_robin.put(input, c_index);
							}

							destinations:
							for (Location out: outputlist) {
								Block target = getAttachedBlock(out.getBlock());
								if (target != null) {
									stack = CargoManager.insert(out.getBlock(), storage, target, stack, -1);
									if (stack == null) break destinations;
								}
							}
						}

						if (stack != null && previousSlot > -1) {
							if (storage.hasUniversalInventory(inputTarget)) {
								UniversalBlockMenu menu = storage.getUniversalInventory(inputTarget);
								menu.replaceExistingItem(previousSlot, stack);
							}
							else if (storage.hasInventory(inputTarget.getLocation())) {
								BlockMenu menu = BlockStorage.getInventory(inputTarget.getLocation());
								menu.replaceExistingItem(previousSlot, stack);
							}
							else if (inputTarget.getState() instanceof InventoryHolder) {
								Inventory inv = ((InventoryHolder) inputTarget.getState()).getInventory();
								inv.setItem(previousSlot, stack);
							}
						}
					}
					//Chest Terminal Code
					if (EXTRA_CHANNELS) {
						List<StoredItem> items = new ArrayList<StoredItem>();
						for (Location l: providers) {
							Block target = getAttachedBlock(l.getBlock());
							if (storage.hasUniversalInventory(target)) {
								UniversalBlockMenu menu = storage.getUniversalInventory(target);
								for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
									ItemStack is = menu.getItemInSlot(slot);
									if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
										boolean add = true;
										for (StoredItem item: items) {
											if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
												add = false;
												item.add(is.getAmount());
											}
										}

										if (add) {
											items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
										}
									}
								}
							}
							else if (storage.hasInventory(target.getLocation())) {
								BlockMenu menu = BlockStorage.getInventory(target.getLocation());
								if (BlockStorage.checkID(target.getLocation()).startsWith("BARREL_") && BlockStorage.getLocationInfo(target.getLocation(), "storedItems") != null) {
									int stored = Integer.valueOf(BlockStorage.getLocationInfo(target.getLocation(), "storedItems"));
									for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
										ItemStack is = menu.getItemInSlot(slot);
										if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
											boolean add = true;
											for (StoredItem item: items) {
												if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
													add = false;
													item.add(is.getAmount() + stored);
												}
											}

											if (add) {
												items.add(new StoredItem(new CustomItem(is, 1), is.getAmount() + stored));
											}
										}
									}
								}
								else {
									for (int slot: menu.getPreset().getSlotsAccessedByItemTransport(menu, ItemTransportFlow.WITHDRAW, null)) {
										ItemStack is = menu.getItemInSlot(slot);
										if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
											boolean add = true;
											for (StoredItem item: items) {
												if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
													add = false;
													item.add(is.getAmount());
												}
											}

											if (add) {
												items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
											}
										}
									}
								}
							}
							else if (target.getState() instanceof InventoryHolder) {
								Inventory inv = ((InventoryHolder) target.getState()).getInventory();
								for (ItemStack is: inv.getContents()) {
									if (is != null && CargoManager.matchesFilter(l.getBlock(), is, -1)) {
										boolean add = true;
										for (StoredItem item: items) {
											if (SlimefunManager.isItemSimiliar(is, item.getItem(), true, DataType.ALWAYS)) {
												add = false;
												item.add(is.getAmount());
											}
										}

										if (add) {
											items.add(new StoredItem(new CustomItem(is, 1), is.getAmount()));
										}
									}
								}
							}
						}

						Collections.sort(items, sorter);

						for (final Location l: terminals) {
							BlockMenu menu = BlockStorage.getInventory(l);
							int page = Integer.parseInt(BlockStorage.getLocationInfo(l, "page"));
							if (!items.isEmpty() && items.size() < (page - 1) * terminal_slots.length + 1) {
								page = 1;
								BlockStorage.addBlockInfo(l, "page", String.valueOf(1));
							}

							for (int i = 0; i < terminal_slots.length; i++) {
								int slot = terminal_slots[i];
								if (items.size() > i + (terminal_slots.length * (page - 1))) {
									final StoredItem item = items.get(i + (terminal_slots.length * (page - 1)));

									ItemStack stack = item.getItem().clone();
									ItemMeta im = stack.getItemMeta();
									List<String> lore = new ArrayList<String>();
									lore.add("");
									lore.add(ChatColor.translateAlternateColorCodes('&', "&7Stored Items: &r" + DoubleHandler.getFancyDouble(item.getAmount())));
									if (stack.getMaxStackSize() > 1) lore.add(ChatColor.translateAlternateColorCodes('&', "&7<Left Click: Request 1 | Right Click: Request " + (item.getAmount() > stack.getMaxStackSize() ? stack.getMaxStackSize(): item.getAmount()) + ">"));
									else lore.add(ChatColor.translateAlternateColorCodes('&', "&7<Left Click: Request 1>"));
									lore.add("");
									if (im.hasLore()) {
										for (String line: im.getLore()) {
											lore.add(line);
										}
									}
									im.setLore(lore);
									stack.setItemMeta(im);
									menu.replaceExistingItem(slot, stack);
									menu.addMenuClickHandler(slot, new MenuClickHandler() {

										@Override
										public boolean onClick(Player p, int slot, ItemStack is, ClickAction action) {
											requests.add(new ItemRequest(l, 44, new CustomItem(item.getItem(), action.isRightClicked() ? (item.getAmount() > item.getItem().getMaxStackSize() ? item.getItem().getMaxStackSize(): item.getAmount()): 1), ItemTransportFlow.WITHDRAW));
											return false;
										}
									});

								}
								else {
									menu.replaceExistingItem(slot, terminal_noitem_item);
									menu.addMenuClickHandler(slot, terminal_noitem_handler);
								}
							}

							ItemStack sent_item = menu.getItemInSlot(17);
							if (sent_item != null) {
								requests.add(new ItemRequest(l, 17, sent_item, ItemTransportFlow.INSERT));
							}
						}
					}

				}
			});
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.api.item_transport.CargoNet.tick.scheduleSyncDelayedTask.new Runnable with () -> {if(BlockStorage.getLocationInfo(b.getLocation(),"visualizer") == null){self.display(); in method public tick(b Block) : void from class me.mrCookieSlime.Slimefun.api.item_transport.CargoNet


	public static void update(final Block b, final String name) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
			ArmorStand hologram = getArmorStand(b);
			hologram.setCustomName(ChatColor.translateAlternateColorCodes('&', name));
		});
	}

	public static void update(final Block b, final String name) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

			@Override
			public void run() {
				ArmorStand hologram = getArmorStand(b);
				hologram.setCustomName(ChatColor.translateAlternateColorCodes('&', name));
			}
		});
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.holograms.CargoHologram.update.scheduleSyncDelayedTask.new Runnable with () -> {ArmorStand hologram=getArmorStand(b); in method public update(b Block, name String) : void from class me.mrCookieSlime.Slimefun.holograms.CargoHologram


Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.holograms.EnergyHologram.update.scheduleSyncDelayedTask.new Runnable with () -> {ArmorStand hologram=getArmorStand(b); in method public update(b Block, name String) : void from class me.mrCookieSlime.Slimefun.holograms.EnergyHologram


	public static void remove(final Block b) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
			ArmorStand hologram = getArmorStand(b);
			hologram.remove();
		});
	}

	public static void remove(final Block b) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

			@Override
			public void run() {
				ArmorStand hologram = getArmorStand(b);
				hologram.remove();
			}
		});
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.holograms.EnergyHologram.remove.scheduleSyncDelayedTask.new Runnable with () -> {ArmorStand hologram=getArmorStand(b); in method public remove(b Block) : void from class me.mrCookieSlime.Slimefun.holograms.EnergyHologram


    public static void update(final Location l, final String name) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
			ArmorStand hologram = getArmorStand(l);
			if (!hologram.isCustomNameVisible()) hologram.setCustomNameVisible(true);
			hologram.setCustomName(ChatColor.translateAlternateColorCodes('&', name));
		});
	}

    public static void update(final Location l, final String name) {
		Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

			@Override
			public void run() {
				ArmorStand hologram = getArmorStand(l);
				if (!hologram.isCustomNameVisible()) hologram.setCustomNameVisible(true);
				hologram.setCustomName(ChatColor.translateAlternateColorCodes('&', name));
			}
		});
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.holograms.ReactorHologram.update.scheduleSyncDelayedTask.new Runnable with () -> {ArmorStand hologram=getArmorStand(l); in method public update(l Location, name String) : void from class me.mrCookieSlime.Slimefun.holograms.ReactorHologram


	@EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true)
	public void onInteract(PlayerInteractEvent e) {
		if (e.getAction() != Action.RIGHT_CLICK_BLOCK) return;
		Block b = e.getClickedBlock();
		SlimefunItem item = BlockStorage.check(b);
		if (item != null) {
			if (item.getID().equals("ANCIENT_PEDESTAL")) {
				if (Variables.altarinuse.contains(b.getLocation())) {
					e.setCancelled(true);
					return;
				}
				e.setCancelled(true);
				Item stack = findItem(b);
				if (stack == null) {
					if(e.getPlayer().getInventory().getItemInMainHand().getType().equals(Material.AIR)) return;
					if(b.getRelative(0, 1, 0).getType() != Material.AIR) {
						Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_PEDESTAL.obstructed", true);
						return;
					}
					insertItem(e.getPlayer(), b);
				}
				else if (!removed_items.contains(stack.getUniqueId())) {
					final UUID uuid = stack.getUniqueId();
					removed_items.add(uuid);

					SlimefunStartup.instance.getServer().getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
						removed_items.remove(uuid);
					}, 30L);

					stack.remove();
					e.getPlayer().getInventory().addItem(fixItemStack(stack.getItemStack(), stack.getCustomName()));
					e.getPlayer().playSound(b.getLocation(), Sound.ENTITY_ITEM_PICKUP, 1F, 1F);
					PlayerInventory.update(e.getPlayer());
				}
			}
			else if (item.getID().equals("ANCIENT_ALTAR")) {
				if (Variables.altarinuse.contains(b.getLocation())) {
					e.setCancelled(true);
					return;
				}
				Variables.altarinuse.add(b.getLocation());  // make altarinuse simply because that was the last block clicked.
				e.setCancelled(true);

				ItemStack catalyst = new CustomItem(e.getPlayer().getInventory().getItemInMainHand(), 1);
				List<Block> pedestals = Pedestals.getPedestals(b);

				if (!altars.contains(e.getClickedBlock())) {
					altars.add(e.getClickedBlock());
					if (pedestals.size() == 8) {
						pedestals.forEach((pblock)->{
							Variables.altarinuse.add(pblock.getLocation());
						});
						if (catalyst != null && !catalyst.getType().equals(Material.AIR)) {
							List<ItemStack> input = new ArrayList<ItemStack>();
							for (Block pedestal: pedestals) {
								Item stack = findItem(pedestal);
								if (stack != null) input.add(fixItemStack(stack.getItemStack(), stack.getCustomName()));
							}

							ItemStack result = Pedestals.getRecipeOutput(catalyst, input);
							if (result != null) {
								List<ItemStack> consumed = new ArrayList<ItemStack>();
								consumed.add(catalyst);
								PlayerInventory.consumeItemInHand(e.getPlayer());
								Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new RitualAnimation(altars, b, b.getLocation().add(0.5, 1.3, 0.5), result, pedestals, consumed), 10L);
							}
							else {
								altars.remove(e.getClickedBlock());
								Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.unknown-recipe", true);
								pedestals.forEach((pblock)->{
									Variables.altarinuse.remove(pblock.getLocation());
								});
								Variables.altarinuse.remove(b.getLocation());  // bad recipe, no longer in use.
							}
						}
						else {
							altars.remove(e.getClickedBlock());
							Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.unknown-catalyst", true);
							pedestals.forEach((pblock)->{
								Variables.altarinuse.remove(pblock.getLocation());
							});
							Variables.altarinuse.remove(b.getLocation());  // unkown catalyst, no longer in use
						}
					}
					else {
						altars.remove(e.getClickedBlock());
						Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.not-enough-pedestals", true, new Variable("%pedestals%", String.valueOf(pedestals.size())));
						Variables.altarinuse.remove(b.getLocation());  // not a valid altar so remove from inuse
					}
				}
			}
		}
	}

	@EventHandler(priority=EventPriority.HIGH, ignoreCancelled = true)
	public void onInteract(PlayerInteractEvent e) {
		if (e.getAction() != Action.RIGHT_CLICK_BLOCK) return;
		Block b = e.getClickedBlock();
		SlimefunItem item = BlockStorage.check(b);
		if (item != null) {
			if (item.getID().equals("ANCIENT_PEDESTAL")) {
				if (Variables.altarinuse.contains(b.getLocation())) {
					e.setCancelled(true);
					return;
				}
				e.setCancelled(true);
				Item stack = findItem(b);
				if (stack == null) {
					if(e.getPlayer().getInventory().getItemInMainHand().getType().equals(Material.AIR)) return;
					if(b.getRelative(0, 1, 0).getType() != Material.AIR) {
						Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_PEDESTAL.obstructed", true);
						return;
					}
					insertItem(e.getPlayer(), b);
				}
				else if (!removed_items.contains(stack.getUniqueId())) {
					final UUID uuid = stack.getUniqueId();
					removed_items.add(uuid);

					SlimefunStartup.instance.getServer().getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

						@Override
						public void run() {
							removed_items.remove(uuid);
						}
					}, 30L);

					stack.remove();
					e.getPlayer().getInventory().addItem(fixItemStack(stack.getItemStack(), stack.getCustomName()));
					e.getPlayer().playSound(b.getLocation(), Sound.ENTITY_ITEM_PICKUP, 1F, 1F);
					PlayerInventory.update(e.getPlayer());
				}
			}
			else if (item.getID().equals("ANCIENT_ALTAR")) {
				if (Variables.altarinuse.contains(b.getLocation())) {
					e.setCancelled(true);
					return;
				}
				Variables.altarinuse.add(b.getLocation());  // make altarinuse simply because that was the last block clicked.
				e.setCancelled(true);

				ItemStack catalyst = new CustomItem(e.getPlayer().getInventory().getItemInMainHand(), 1);
				List<Block> pedestals = Pedestals.getPedestals(b);

				if (!altars.contains(e.getClickedBlock())) {
					altars.add(e.getClickedBlock());
					if (pedestals.size() == 8) {
						pedestals.forEach((pblock)->{
							Variables.altarinuse.add(pblock.getLocation());
						});
						if (catalyst != null && !catalyst.getType().equals(Material.AIR)) {
							List<ItemStack> input = new ArrayList<ItemStack>();
							for (Block pedestal: pedestals) {
								Item stack = findItem(pedestal);
								if (stack != null) input.add(fixItemStack(stack.getItemStack(), stack.getCustomName()));
							}

							ItemStack result = Pedestals.getRecipeOutput(catalyst, input);
							if (result != null) {
								List<ItemStack> consumed = new ArrayList<ItemStack>();
								consumed.add(catalyst);
								PlayerInventory.consumeItemInHand(e.getPlayer());
								Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new RitualAnimation(altars, b, b.getLocation().add(0.5, 1.3, 0.5), result, pedestals, consumed), 10L);
							}
							else {
								altars.remove(e.getClickedBlock());
								Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.unknown-recipe", true);
								pedestals.forEach((pblock)->{
									Variables.altarinuse.remove(pblock.getLocation());
								});
								Variables.altarinuse.remove(b.getLocation());  // bad recipe, no longer in use.
							}
						}
						else {
							altars.remove(e.getClickedBlock());
							Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.unknown-catalyst", true);
							pedestals.forEach((pblock)->{
								Variables.altarinuse.remove(pblock.getLocation());
							});
							Variables.altarinuse.remove(b.getLocation());  // unkown catalyst, no longer in use
						}
					}
					else {
						altars.remove(e.getClickedBlock());
						Messages.local.sendTranslation(e.getPlayer(), "machines.ANCIENT_ALTAR.not-enough-pedestals", true, new Variable("%pedestals%", String.valueOf(pedestals.size())));
						Variables.altarinuse.remove(b.getLocation());  // not a valid altar so remove from inuse
					}
				}
			}
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.listeners.AncientAltarListener.onInteract.scheduleSyncDelayedTask.new Runnable with () -> {removed_items.remove(uuid); in method public onInteract(e PlayerInteractEvent) : void from class me.mrCookieSlime.Slimefun.listeners.AncientAltarListener


	@EventHandler(priority = EventPriority.HIGHEST)
	public void onDeath(final EntityDeathEvent e) {
		if (e.getEntity().hasMetadata("android_killer")) {
			for (MetadataValue value: e.getEntity().getMetadata("android_killer")) {
				final AndroidObject obj = (AndroidObject) value.value();
				Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
					List<ItemStack> items = new ArrayList<ItemStack>();
					for (Entity n : e.getEntity().getNearbyEntities(0.5D, 0.5D, 0.5D)) {
						if (n instanceof Item && !n.hasMetadata("no_pickup")) {
							items.add(((Item) n).getItemStack());
							n.remove();
						}
					}

					switch (e.getEntityType()) {
						case BLAZE: {
							items.add(new ItemStack(Material.BLAZE_ROD, 1 + CSCoreLib.randomizer().nextInt(2)));
							break;
						}
						case PIG_ZOMBIE: {
							items.add(new ItemStack(Material.GOLD_NUGGET, 1 + CSCoreLib.randomizer().nextInt(3)));
							break;
						}
						case WITHER_SKELETON: {
							if (CSCoreLib.randomizer().nextInt(250) < 2) items.add(new ItemStack(Material.WITHER_SKELETON_SKULL));
							break;
						}
						default:
							break;
					}

					obj.getAndroid().addItems(obj.getBlock(), items.toArray(new ItemStack[items.size()]));
					ExperienceOrb exp = (ExperienceOrb) e.getEntity().getWorld().spawnEntity(e.getEntity().getLocation(), EntityType.EXPERIENCE_ORB);
					exp.setExperience(1 + CSCoreLib.randomizer().nextInt(6));
				}, 1L);
				return;
			}
		}
	}

	@EventHandler(priority=EventPriority.HIGHEST)
	public void onDeath(final EntityDeathEvent e) {
		if (e.getEntity().hasMetadata("android_killer")) {
			for (MetadataValue value: e.getEntity().getMetadata("android_killer")) {
				final AndroidObject obj = (AndroidObject) value.value();
				Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

					@Override
					public void run() {
						List<ItemStack> items = new ArrayList<ItemStack>();
						for (Entity n: e.getEntity().getNearbyEntities(0.5D, 0.5D, 0.5D)) {
							if (n instanceof Item && !n.hasMetadata("no_pickup")) {
								items.add(((Item) n).getItemStack());
								n.remove();
							}
						}

						switch (e.getEntityType()) {
						case BLAZE: {
							items.add(new ItemStack(Material.BLAZE_ROD, 1 + CSCoreLib.randomizer().nextInt(2)));
							break;
						}
						case PIG_ZOMBIE: {
							items.add(new ItemStack(Material.GOLD_NUGGET, 1 + CSCoreLib.randomizer().nextInt(3)));
							break;
						}
						case WITHER_SKELETON: {
							if (CSCoreLib.randomizer().nextInt(250) < 2) items.add(new ItemStack(Material.WITHER_SKELETON_SKULL));
							break;
						}
						default:
							break;
						}

						obj.getAndroid().addItems(obj.getBlock(), items.toArray(new ItemStack[items.size()]));
						ExperienceOrb exp = (ExperienceOrb) e.getEntity().getWorld().spawnEntity(e.getEntity().getLocation(), EntityType.EXPERIENCE_ORB);
						exp.setExperience(1 + CSCoreLib.randomizer().nextInt(6));
					}
				}, 1L);
				return;
			}
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.listeners.AndroidKillingListener.onDeath.scheduleSyncDelayedTask.new Runnable with () -> {List<ItemStack> items=new ArrayList<ItemStack>(); in method public onDeath(e EntityDeathEvent) : void from class me.mrCookieSlime.Slimefun.listeners.AndroidKillingListener


	private void handleGrapplingHook(Arrow arrow) {
		if (arrow != null) {
			if (arrow.getShooter() instanceof Player && Variables.jump.containsKey(((Player) arrow.getShooter()).getUniqueId())) {
				final Player p = (Player) arrow.getShooter();
				if (p.getGameMode() != GameMode.CREATIVE && Variables.jump.get(p.getUniqueId())) arrow.getWorld().dropItem(arrow.getLocation(), SlimefunItem.getItem("GRAPPLING_HOOK"));
				if (p.getLocation().distance(arrow.getLocation()) < 3.0D) {
					if (arrow.getLocation().getY() > p.getLocation().getY()) {
						p.setVelocity(new Vector(0.0D, 0.25D, 0.0D));
					}
					else p.setVelocity(arrow.getLocation().toVector().subtract(p.getLocation().toVector()));
					for (Entity n: Variables.remove.get(p.getUniqueId())) {
		    	    	n.remove();
		    	    }

		    	    Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
						Variables.jump.remove(p.getUniqueId());
						Variables.remove.remove(p.getUniqueId());
					}, 20L);
				}
				else {
					Location l = p.getLocation();
					l.setY(l.getY() + 0.5D);
					p.teleport(l);

					double g = -0.08D;
		    	    double d = arrow.getLocation().distance(l);
		    	    double t = d;
		    	    double v_x = (1.0D + 0.08000000000000001D * t) * (arrow.getLocation().getX() - l.getX()) / t;
		    	    double v_y = (1.0D + 0.04D * t) * (arrow.getLocation().getY() - l.getY()) / t - 0.5D * g * t;
		    	    double v_z = (1.0D + 0.08000000000000001D * t) * (arrow.getLocation().getZ() - l.getZ()) / t;

		    	    Vector v = p.getVelocity();

		    	    v.setX(v_x);
		    	    v.setY(v_y);
		    	    v.setZ(v_z);

		    	    p.setVelocity(v);

		    	    for (Entity n: Variables.remove.get(p.getUniqueId())) {
		    	    	n.remove();
		    	    }

		    	    Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
						Variables.jump.remove(p.getUniqueId());
						Variables.remove.remove(p.getUniqueId());
					}, 20L);
				}
			}
		}
	}

	private void handleGrapplingHook(Arrow arrow) {
		if (arrow != null) {
			if (arrow.getShooter() instanceof Player && Variables.jump.containsKey(((Player) arrow.getShooter()).getUniqueId())) {
				final Player p = (Player) arrow.getShooter();
				if (p.getGameMode() != GameMode.CREATIVE && Variables.jump.get(p.getUniqueId())) arrow.getWorld().dropItem(arrow.getLocation(), SlimefunItem.getItem("GRAPPLING_HOOK"));
				if (p.getLocation().distance(arrow.getLocation()) < 3.0D) {
					if (arrow.getLocation().getY() > p.getLocation().getY()) {
						p.setVelocity(new Vector(0.0D, 0.25D, 0.0D));
					}
					else p.setVelocity(arrow.getLocation().toVector().subtract(p.getLocation().toVector()));
					for (Entity n: Variables.remove.get(p.getUniqueId())) {
		    	    	n.remove();
		    	    }

		    	    Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
						Variables.jump.remove(p.getUniqueId());
						Variables.remove.remove(p.getUniqueId());
					}, 20L);
				}
				else {
					Location l = p.getLocation();
					l.setY(l.getY() + 0.5D);
					p.teleport(l);

					double g = -0.08D;
		    	    double d = arrow.getLocation().distance(l);
		    	    double t = d;
		    	    double v_x = (1.0D + 0.08000000000000001D * t) * (arrow.getLocation().getX() - l.getX()) / t;
		    	    double v_y = (1.0D + 0.04D * t) * (arrow.getLocation().getY() - l.getY()) / t - 0.5D * g * t;
		    	    double v_z = (1.0D + 0.08000000000000001D * t) * (arrow.getLocation().getZ() - l.getZ()) / t;

		    	    Vector v = p.getVelocity();

		    	    v.setX(v_x);
		    	    v.setY(v_y);
		    	    v.setZ(v_z);

		    	    p.setVelocity(v);

		    	    for (Entity n: Variables.remove.get(p.getUniqueId())) {
		    	    	n.remove();
		    	    }

		    	    Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

						@Override
						public void run() {
							Variables.jump.remove(p.getUniqueId());
							Variables.remove.remove(p.getUniqueId());
						}
					}, 20L);
				}
			}
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.listeners.BowListener.handleGrapplingHook.scheduleSyncDelayedTask.new Runnable with () -> {Variables.jump.remove(p.getUniqueId()); in method private handleGrapplingHook(arrow Arrow) : void from class me.mrCookieSlime.Slimefun.listeners.BowListener


	@EventHandler
	public void onEat(PlayerItemConsumeEvent e) {
		if (e.getItem() != null) {
			final Player p = e.getPlayer();
			ItemStack item = e.getItem();
			if (Slimefun.hasUnlocked(p, item, true)) {
				if (SlimefunManager.isItemSimiliar(item, SlimefunItems.MONSTER_JERKY, true)) {
					e.setCancelled(true);
					if (SlimefunManager.isItemSimiliar(p.getInventory().getItemInOffHand(), SlimefunItems.MONSTER_JERKY, true)) {
						p.getInventory().setItemInOffHand(InvUtils.decreaseItem(p.getInventory().getItemInOffHand(), 1));
					}
					else{
						p.getInventory().setItemInMainHand(InvUtils.decreaseItem(p.getInventory().getItemInMainHand(), 1));
					}
					PlayerInventory.update(p);
					p.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, 5, 0));
				}
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.FORTUNE_COOKIE, true)) p.sendMessage(ChatColor.translateAlternateColorCodes('&', Messages.local.getTranslation("messages.fortune-cookie").get(CSCoreLib.randomizer().nextInt(Messages.local.getTranslation("messages.fortune-cookie").size()))));
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.BEEF_JERKY, true)) p.setSaturation((Integer) Slimefun.getItemValue("BEEF_JERKY", "Saturation"));
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.MEDICINE, true)) {
					if (p.hasPotionEffect(PotionEffectType.POISON)) p.removePotionEffect(PotionEffectType.POISON);
					if (p.hasPotionEffect(PotionEffectType.WITHER)) p.removePotionEffect(PotionEffectType.WITHER);
					if (p.hasPotionEffect(PotionEffectType.SLOW)) p.removePotionEffect(PotionEffectType.SLOW);
					if (p.hasPotionEffect(PotionEffectType.SLOW_DIGGING)) p.removePotionEffect(PotionEffectType.SLOW_DIGGING);
					if (p.hasPotionEffect(PotionEffectType.WEAKNESS)) p.removePotionEffect(PotionEffectType.WEAKNESS);
					if (p.hasPotionEffect(PotionEffectType.CONFUSION)) p.removePotionEffect(PotionEffectType.CONFUSION);
					if (p.hasPotionEffect(PotionEffectType.BLINDNESS)) p.removePotionEffect(PotionEffectType.BLINDNESS);
					p.setFireTicks(0);
				}
				else if (item.getType() == Material.POTION) {
					SlimefunItem sfItem = SlimefunItem.getByItem(item);
					if (sfItem != null && sfItem instanceof Juice) {
						// Fix for Saturation on potions is no longer working
						for (PotionEffect effect : ((PotionMeta) item.getItemMeta()).getCustomEffects()) {
							if (effect.getType().equals(PotionEffectType.SATURATION)) {
								p.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, effect.getDuration(), effect.getAmplifier()));
								break;
							}
						}

						// Determine from which hand the juice is being drunk, and its amount
						int mode = 0;
						if (SlimefunManager.isItemSimiliar(item, p.getInventory().getItemInMainHand(), true)) {
							if (p.getInventory().getItemInMainHand().getAmount() == 1) {
								mode = 0;
							}
							else {
								mode = 2;
							}
						}
						else if (SlimefunManager.isItemSimiliar(item, p.getInventory().getItemInOffHand(), true)) {
							if (p.getInventory().getItemInOffHand().getAmount() == 1) {
								mode = 1;
							}
							else {
								mode = 2;
							}
						}

						// Remove the glass bottle once drunk
						final int m = mode;

						Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, () -> {
							if (m == 0) p.getEquipment().setItemInMainHand(null);
							else if (m == 1) p.getEquipment().setItemInOffHand(null);
							else if (m == 2) p.getInventory().removeItem(new ItemStack(Material.GLASS_BOTTLE, 1));
						}, 0L);
					}
				}
			}
			else e.setCancelled(true);
		}
	}

	@EventHandler
	public void onEat(PlayerItemConsumeEvent e) {
		if (e.getItem() != null) {
			final Player p = e.getPlayer();
			ItemStack item = e.getItem();
			if (Slimefun.hasUnlocked(p, item, true)) {
				if (SlimefunManager.isItemSimiliar(item, SlimefunItems.MONSTER_JERKY, true)) {
					e.setCancelled(true);
					if (SlimefunManager.isItemSimiliar(p.getInventory().getItemInOffHand(), SlimefunItems.MONSTER_JERKY, true)) {
						p.getInventory().setItemInOffHand(InvUtils.decreaseItem(p.getInventory().getItemInOffHand(), 1));
					}
					else{
						p.getInventory().setItemInMainHand(InvUtils.decreaseItem(p.getInventory().getItemInMainHand(), 1));
					}
					PlayerInventory.update(p);
					p.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, 5, 0));
				}
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.FORTUNE_COOKIE, true)) p.sendMessage(ChatColor.translateAlternateColorCodes('&', Messages.local.getTranslation("messages.fortune-cookie").get(CSCoreLib.randomizer().nextInt(Messages.local.getTranslation("messages.fortune-cookie").size()))));
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.BEEF_JERKY, true)) p.setSaturation((Integer) Slimefun.getItemValue("BEEF_JERKY", "Saturation"));
				else if (SlimefunManager.isItemSimiliar(item, SlimefunItems.MEDICINE, true)) {
					if (p.hasPotionEffect(PotionEffectType.POISON)) p.removePotionEffect(PotionEffectType.POISON);
					if (p.hasPotionEffect(PotionEffectType.WITHER)) p.removePotionEffect(PotionEffectType.WITHER);
					if (p.hasPotionEffect(PotionEffectType.SLOW)) p.removePotionEffect(PotionEffectType.SLOW);
					if (p.hasPotionEffect(PotionEffectType.SLOW_DIGGING)) p.removePotionEffect(PotionEffectType.SLOW_DIGGING);
					if (p.hasPotionEffect(PotionEffectType.WEAKNESS)) p.removePotionEffect(PotionEffectType.WEAKNESS);
					if (p.hasPotionEffect(PotionEffectType.CONFUSION)) p.removePotionEffect(PotionEffectType.CONFUSION);
					if (p.hasPotionEffect(PotionEffectType.BLINDNESS)) p.removePotionEffect(PotionEffectType.BLINDNESS);
					p.setFireTicks(0);
				}
				else if (item.getType() == Material.POTION) {
					SlimefunItem sfItem = SlimefunItem.getByItem(item);
					if (sfItem != null && sfItem instanceof Juice) {
						// Fix for Saturation on potions is no longer working
						for (PotionEffect effect : ((PotionMeta) item.getItemMeta()).getCustomEffects()) {
							if (effect.getType().equals(PotionEffectType.SATURATION)) {
								p.addPotionEffect(new PotionEffect(PotionEffectType.SATURATION, effect.getDuration(), effect.getAmplifier()));
								break;
							}
						}

						// Determine from which hand the juice is being drunk, and its amount
						int mode = 0;
						if (SlimefunManager.isItemSimiliar(item, p.getInventory().getItemInMainHand(), true)) {
							if (p.getInventory().getItemInMainHand().getAmount() == 1) {
								mode = 0;
							}
							else {
								mode = 2;
							}
						}
						else if (SlimefunManager.isItemSimiliar(item, p.getInventory().getItemInOffHand(), true)) {
							if (p.getInventory().getItemInOffHand().getAmount() == 1) {
								mode = 1;
							}
							else {
								mode = 2;
							}
						}

						// Remove the glass bottle once drunk
						final int m = mode;

						Bukkit.getScheduler().scheduleSyncDelayedTask(SlimefunStartup.instance, new Runnable() {

							@Override
							public void run() {
								if (m == 0) p.getEquipment().setItemInMainHand(null);
								else if (m == 1) p.getEquipment().setItemInOffHand(null);
								else if (m == 2) p.getInventory().removeItem(new ItemStack(Material.GLASS_BOTTLE, 1));
							}

						}, 0L);
					}
				}
			}
			else e.setCancelled(true);
		}
	}

Replace Anonymous With Lambda me.mrCookieSlime.Slimefun.listeners.ItemListener.onEat.scheduleSyncDelayedTask.new Runnable with () -> {if(m == 0)p.getEquipment().setItemInMainHand(null); in method public onEat(e PlayerItemConsumeEvent) : void from class me.mrCookieSlime.Slimefun.listeners.ItemListener