Holdclick banner
Holdclick icon

Holdclick

You are an experienced Minecraft Fabric mod developer. Write a CLIENT-SIDE Fabric mod for Minecraft (Fabric API, Yarn mappings) with the following...

00
fabricBoth1.20.1mod

Holdclick

  • Client-side toggleable auto-click/auto-mine: when enabled and the left mouse button is held, the mod sends start/continue/stop destroy packets once per tick for the looked-at block, with reach/distance checks and automatic cancel when the target becomes invalid or a screen is open.
  • Toggle keybinding: default H in the Holdclick category; each press flips the feature and prints a chat message so you know whether it is enabled.
  • Optional tracers: when the feature is enabled, clean lines render from your eyes to other players within 60 blocks (local player excluded) during world rendering.
  • Implementation notes: uses Fabric client tick + world render events, ClientPlayerInteractionManager.attackBlock/updateBlockBreakingProgress/cancelBlockBreaking, and swing animations to mirror normal mining without packet spam.
  • Limitations/suggestions: tracer style is minimal (single colored line) and tied to the auto-click toggle; consider adding a separate toggle or customization if desired.

Server Validation

Server validation passed - The mod was tested on a real Minecraft server and loaded successfully.