mirror of
https://github.com/StarWishsama/Slimefun4.git
synced 2024-09-20 11:45:51 +00:00
Fixed compilation
This commit is contained in:
parent
26a64004d2
commit
2ff24c2889
@ -39,21 +39,21 @@ public abstract class SimpleBlockBreakHandler extends BlockBreakHandler {
|
|||||||
* @param b
|
* @param b
|
||||||
* The broken {@link Block}
|
* The broken {@link Block}
|
||||||
*/
|
*/
|
||||||
public abstract void onBlockBreaking(@Nonnull Block b);
|
public abstract void onBlockBreak(@Nonnull Block b);
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onPlayerBreak(BlockBreakEvent e, ItemStack item, List<ItemStack> drops) {
|
public void onPlayerBreak(BlockBreakEvent e, ItemStack item, List<ItemStack> drops) {
|
||||||
onBlockBreaking(e.getBlock());
|
onBlockBreak(e.getBlock());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onAndroidBreak(AndroidMineEvent e) {
|
public void onAndroidBreak(AndroidMineEvent e) {
|
||||||
onBlockBreaking(e.getBlock());
|
onBlockBreak(e.getBlock());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onExplode(Block b, List<ItemStack> drops) {
|
public void onExplode(Block b, List<ItemStack> drops) {
|
||||||
onBlockBreaking(b);
|
onBlockBreak(b);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -62,7 +62,7 @@ public class AncientPedestal extends SimpleSlimefunItem<BlockDispenseHandler> {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
Optional<Item> entity = getPlacedItem(b);
|
Optional<Item> entity = getPlacedItem(b);
|
||||||
|
|
||||||
if (entity.isPresent()) {
|
if (entity.isPresent()) {
|
||||||
|
@ -1,7 +1,5 @@
|
|||||||
package io.github.thebusybiscuit.slimefun4.implementation.items.blocks;
|
package io.github.thebusybiscuit.slimefun4.implementation.items.blocks;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
import javax.annotation.Nonnull;
|
import javax.annotation.Nonnull;
|
||||||
import javax.annotation.ParametersAreNonnullByDefault;
|
import javax.annotation.ParametersAreNonnullByDefault;
|
||||||
|
|
||||||
@ -11,18 +9,17 @@ import org.bukkit.block.Block;
|
|||||||
import org.bukkit.entity.ArmorStand;
|
import org.bukkit.entity.ArmorStand;
|
||||||
import org.bukkit.entity.Entity;
|
import org.bukkit.entity.Entity;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.event.block.BlockBreakEvent;
|
|
||||||
import org.bukkit.event.block.BlockPlaceEvent;
|
import org.bukkit.event.block.BlockPlaceEvent;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
import io.github.thebusybiscuit.cscorelib2.chat.ChatColors;
|
import io.github.thebusybiscuit.cscorelib2.chat.ChatColors;
|
||||||
import io.github.thebusybiscuit.cscorelib2.item.CustomItem;
|
import io.github.thebusybiscuit.cscorelib2.item.CustomItem;
|
||||||
import io.github.thebusybiscuit.cscorelib2.math.DoubleHandler;
|
import io.github.thebusybiscuit.cscorelib2.math.DoubleHandler;
|
||||||
import io.github.thebusybiscuit.slimefun4.api.events.AndroidMineEvent;
|
|
||||||
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockBreakHandler;
|
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockBreakHandler;
|
||||||
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockPlaceHandler;
|
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockPlaceHandler;
|
||||||
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockUseHandler;
|
import io.github.thebusybiscuit.slimefun4.core.handlers.BlockUseHandler;
|
||||||
import io.github.thebusybiscuit.slimefun4.implementation.SlimefunPlugin;
|
import io.github.thebusybiscuit.slimefun4.implementation.SlimefunPlugin;
|
||||||
|
import io.github.thebusybiscuit.slimefun4.implementation.handlers.SimpleBlockBreakHandler;
|
||||||
import io.github.thebusybiscuit.slimefun4.utils.ChatUtils;
|
import io.github.thebusybiscuit.slimefun4.utils.ChatUtils;
|
||||||
import io.github.thebusybiscuit.slimefun4.utils.holograms.SimpleHologram;
|
import io.github.thebusybiscuit.slimefun4.utils.holograms.SimpleHologram;
|
||||||
import me.mrCookieSlime.CSCoreLibPlugin.general.Inventory.ChestMenu;
|
import me.mrCookieSlime.CSCoreLibPlugin.general.Inventory.ChestMenu;
|
||||||
@ -65,7 +62,7 @@ public class HologramProjector extends SlimefunItem {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
remove(b);
|
remove(b);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -48,7 +48,7 @@ abstract class AbstractFilterNode extends AbstractCargoNode {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
BlockMenu inv = BlockStorage.getInventory(b);
|
BlockMenu inv = BlockStorage.getInventory(b);
|
||||||
|
|
||||||
if (inv != null) {
|
if (inv != null) {
|
||||||
|
@ -38,7 +38,7 @@ public class CargoManager extends SlimefunItem {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
SimpleHologram.remove(b);
|
SimpleHologram.remove(b);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -108,7 +108,7 @@ public class ReactorAccessPort extends SlimefunItem {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
BlockMenu inv = BlockStorage.getInventory(b);
|
BlockMenu inv = BlockStorage.getInventory(b);
|
||||||
|
|
||||||
if (inv != null) {
|
if (inv != null) {
|
||||||
|
@ -44,7 +44,7 @@ public class EnergyRegulator extends SlimefunItem {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
SimpleHologram.remove(b);
|
SimpleHologram.remove(b);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -118,7 +118,7 @@ public abstract class Reactor extends AbstractEnergyProvider {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
BlockMenu inv = BlockStorage.getInventory(b);
|
BlockMenu inv = BlockStorage.getInventory(b);
|
||||||
|
|
||||||
if (inv != null) {
|
if (inv != null) {
|
||||||
|
@ -66,7 +66,7 @@ public class GEOMiner extends AContainer implements RecipeDisplayItem {
|
|||||||
return new SimpleBlockBreakHandler() {
|
return new SimpleBlockBreakHandler() {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onBlockBreaking(@Nonnull Block b) {
|
public void onBlockBreak(@Nonnull Block b) {
|
||||||
SimpleHologram.remove(b);
|
SimpleHologram.remove(b);
|
||||||
|
|
||||||
BlockMenu inv = BlockStorage.getInventory(b);
|
BlockMenu inv = BlockStorage.getInventory(b);
|
||||||
|
Loading…
Reference in New Issue
Block a user