MonitoringMinecraft MonitoringMinecraft
O

open-hands-lib

Мод NeoForge

Open Hands Lib is a library for Minecraft. Each hand has its own hit cooldown, and the damage and tool are passed through the hand that your mod chooses; the same can be enabled for breaking blocks

3 скачивания 0 подписчиков
Оцените первым

Open Hands Lib

Per-hand melee cooldowns and mining for NeoForge content mods.

If you are not a mod developer, this is a dependency mod.
Install it only when another mod lists open_hands_lib as a required dependency. On its own it does not add items, blocks, or gameplay.


What is Open Hands Lib?

A NeoForge library that splits attack and mining logic across main hand and off hand. Each hand gets its own cooldown timer; your content mod decides when the system is active and which hand to use.

The library owns timers, mixins, and state. Your mod registers enable conditions and handles events — the library does not pick duelist logic for you.


Features

Combat (when enabled for a player)

  • Independent cooldown per hand
  • Attacks only land at full charge — partial swings are rejected on purpose
  • Hand selection via ResolveAttackHandEvent (alternation, best weapon, etc.)
  • Damage, enchantments, and weapon effects use the resolved hand
  • Optional rules to attack with the main hand while the off hand is using an item

Combat activates when any registered condition is true (OR).

Mining (when enabled)

  • Tool, harvest check, speed, and durability follow the resolved hand
  • Hand selection via ResolveMiningHandEvent
  • Per-block session cache until mining stops

Mining activates when any registered condition is true (OR).


Requirements

NeoForge 21.1.219+
Kotlin for Forge 5.9.0+ (required)
Mod ID open_hands_lib
Author Thow New Error

Installation

  1. Install NeoForge
  2. Install Kotlin for Forge
  3. Install Open Hands Lib and the content mod that depends on it

Do not rename the mod or swap the jar for an unofficial build in public modpacks.


For mod developers

Register when your gameplay should turn on, then listen for hand events:

OpenHandsLib.registerEnableCondition(
    ResourceLocation.fromNamespaceAndPath("your_mod", "dual_wield"),
) { player -> /* your check */ true }

NeoForge.EVENT_BUS.register(object {
    @SubscribeEvent
    fun onResolveAttackHand(event: ResolveAttackHandEvent) {
        event.hand = InteractionHand.MAIN_HAND
    }

    @SubscribeEvent
    fun onAttackHandCompleted(event: AttackHandCompletedEvent) {
        // alternation, etc.
    }
})

Mining: registerMiningEnableCondition + ResolveMiningHandEvent.

Public API

  • mod.openhandslib.api.OpenHandsLib — entry point
  • ResolveAttackHandEvent, AttackHandCompletedEvent, OpenHandsCombatStateClearEvent
  • ResolveMiningHandEvent
Смотри также

Похожие подборки моды — по версиям Майнкрафта, загрузчикам и жанрам.

Сервера Майнкрафт

Играть интереснее на сервере — выбирай в рейтинге серверов Майнкрафт и заходи прямо сейчас.

SkyBars
SkyBars Java + BE
432 онлайн
1.8 — 26.2 версия
🎮 ВЫЖИВАНИЕ ⚔️ АНАРХИЯ 🚗 ГТА РП 🎤 ГОЛОСОВОЙ ЧАТ 🎁 БЕСПЛАТНЫЙ ДОНАТ 🌟 СМП 💻 ПК+ТЕЛЕФОН
MigosMc
MigosMc Java + BE
284 онлайн
1.8 — 26.2 версия
🌿 MigosMc.net | Гриферский сервер с войс-чатом | Награды за онлайн ⭐ ВЫЖИВАНИЕ⭐ ОДИНБЛОК⭐ МИНИ-ИГРЫ
SeasonEra
0 онлайн
26.1.2 версия
Выживание • Экономика • Кланы • Приваты • Донат
PLIRGAME - ДЕВУШКИ ВОЙС ЧАТ
29 онлайн
1.21.10 — 26.1.1 версия
❤️ Выживание! ❤️ Войс Чат ❤️ Девушки ❤️ /free
MineLauncher
Лаунчер Майнкрафт без лицензии — все версии
Бесплатный лаунчер для ПК и Андроид — все версии 26.2, 1.21.11, 26.1.2, 1.21.8. Fabric, NeoForge, Forge, шейдеры, моды и скины в один клик.
Без лицензии Fabric, NeoForge, Forge Моды, шейдеры, скины Все версии Майнкрафта ПК и Андроид Для слабых ПК Сервера в лаунчере
Скачать бесплатно
Windows и Андроид · Бесплатно · Без лицензии
Наш чат