BlockInteractEvent Type clarification

This commit is contained in:
Brady 2018-12-13 18:22:33 -06:00
parent d89aa887fb
commit 35efd9293b
No known key found for this signature in database
GPG Key ID: 73A788379A197567
2 changed files with 4 additions and 4 deletions

View File

@ -20,7 +20,7 @@ package baritone.api.event.events;
import net.minecraft.util.math.BlockPos;
/**
* Called when the local player interacts with a block, can be either {@link Type#BREAK} or {@link Type#USE}.
* Called when the local player interacts with a block, can be either {@link Type#START_BREAK} or {@link Type#USE}.
*
* @author Brady
* @since 8/22/2018
@ -59,9 +59,9 @@ public final class BlockInteractEvent {
public enum Type {
/**
* We're breaking the target block.
* We're starting to break the target block.
*/
BREAK,
START_BREAK,
/**
* We're right clicking on the target block. Either placing or interacting with.

View File

@ -164,7 +164,7 @@ public class MixinMinecraft {
)
private void onBlockBreak(CallbackInfo ci, BlockPos pos) {
// clickMouse is only for the main player
BaritoneAPI.getProvider().getPrimaryBaritone().getGameEventHandler().onBlockInteract(new BlockInteractEvent(pos, BlockInteractEvent.Type.BREAK));
BaritoneAPI.getProvider().getPrimaryBaritone().getGameEventHandler().onBlockInteract(new BlockInteractEvent(pos, BlockInteractEvent.Type.START_BREAK));
}
@Inject(