diff options
| author | Kevin <92656833+kevinthegreat1@users.noreply.github.com> | 2024-01-01 14:49:31 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-01-01 01:49:31 -0500 |
| commit | 8005dd9afe963a461619ee3da603d8202292840b (patch) | |
| tree | ec35f59554a2bb9ed349128020e6b3a1ce410c59 /src/main/java/de/hysky/skyblocker/events | |
| parent | c6a24637bea5f6d6534e88750d011270d7b612dc (diff) | |
| download | Skyblocker-8005dd9afe963a461619ee3da603d8202292840b.tar.gz Skyblocker-8005dd9afe963a461619ee3da603d8202292840b.tar.bz2 Skyblocker-8005dd9afe963a461619ee3da603d8202292840b.zip | |
Migrate to Fabric Api ClientPlayerBlockBreakEvents (#466)
* Migrate to fabric api ClientPlayerBlockBreakEvents
* Update fapi requirement
Diffstat (limited to 'src/main/java/de/hysky/skyblocker/events')
| -rw-r--r-- | src/main/java/de/hysky/skyblocker/events/ClientPlayerBlockBreakEvent.java | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/src/main/java/de/hysky/skyblocker/events/ClientPlayerBlockBreakEvent.java b/src/main/java/de/hysky/skyblocker/events/ClientPlayerBlockBreakEvent.java deleted file mode 100644 index 83ac716f..00000000 --- a/src/main/java/de/hysky/skyblocker/events/ClientPlayerBlockBreakEvent.java +++ /dev/null @@ -1,23 +0,0 @@ -package de.hysky.skyblocker.events; - -import net.fabricmc.fabric.api.event.Event; -import net.fabricmc.fabric.api.event.EventFactory; -import net.minecraft.block.BlockState; -import net.minecraft.entity.player.PlayerEntity; -import net.minecraft.util.math.BlockPos; -import net.minecraft.world.World; - -// Fabric API currently doesn't have an event for this -public class ClientPlayerBlockBreakEvent { - public static final Event<AfterBlockBreak> AFTER = EventFactory.createArrayBacked(AfterBlockBreak.class, - (listeners) -> (world, player, pos, state) -> { - for (AfterBlockBreak listener : listeners) { - listener.afterBlockBreak(world, player, pos, state); - } - }); - - @FunctionalInterface - public interface AfterBlockBreak { - void afterBlockBreak(World world, PlayerEntity player, BlockPos pos, BlockState state); - } -} |
