CobSwap
CobSwap 是一款客户端 Fabric 模组,可在战斗期间为你自动放置蛛网。手持剑或斧头时,左键点击对手旁边的方块,它会自动切换到你的蛛网、放置蛛网,然后切换回武器。该模组使用正常的物品栏切换和方块放置机制,并支持调整步骤间的延迟时间。
无需安装服务端组件。
功能特性
- 一键放置蛛网。 手持剑或斧头时左键点击方块,CobSwap 会自动处理切换、放置和切回操作。
- 战斗感知。 仅当目标区域附近约 3 格内存在生物(玩家或怪物),且该位置为空时才会触发。在其他情况下,挖掘功能保持正常。
- 不影响普通攻击。 CobSwap 仅响应对方块的左键点击。攻击玩家或怪物的操作与原版完全一致。
- 可调节延迟。 步骤间的等待时间默认为 2 刻(约 100 毫秒),范围可在 0 到 10 刻之间设置。你可以在游戏中实时更改此设置,并将配置保存至
config/cobswap.json。
- 开关切换。 每次启动游戏时,模组默认处于关闭状态,以防止意外触发。这也避免了在使用剑进行挖掘时自动放置蛛网。
- 按键可重绑。 所有按键绑定均可在“选项 > 控制 > 按键绑定 > CobSwap”中查看和修改。
- 动作栏反馈。 切换开关和调整延迟时,会在快捷栏上方显示简短提示信息。
工作原理
当 CobSwap 开启时,必须同时满足以下条件:
- 主手持有剑或斧头。
- 左键点击一个方块(而非实体)。
- 被点击面旁边的空间为空。
- 在该空间附近约 3 格内存在活体生物。
- 快捷栏(1-9 号槽位)中包含蛛网。
随后,CobSwap 会取消正常的挖掘动作,切换到蛛网所在槽位,等待设定的延迟时间,放置蛛网,再次等待后,切换回原来的物品槽位。如果任一条件不满足,点击操作将按原版 Minecraft 的方式执行。
默认控制
| 操作 |
按键 |
| 切换 CobSwap 开/关 |
G |
| 增加延迟 (+1 刻) |
] |
| 减少延迟 (-1 刻) |
[ |
以上所有按键均可在“控制”菜单中重新绑定。
依赖要求
- Minecraft 1.21.11
- Fabric Loader 0.19.3 或更高版本
- Fabric API
- Java 21
安装步骤
- 为 Minecraft 1.21.11 安装 Fabric Loader。
- 将 Fabric API 和 CobSwap jar 文件放入
mods 文件夹。
- 使用 Fabric 配置文件启动游戏,并在“控制”中检查按键绑定。
重要提示
CobSwap 自动化了战斗中重复性的物品栏操作。许多多人服务器禁止宏命令或自动化行为,部分反作弊系统甚至会将快速的物品栏操作标记为异常,即使每个操作本身都是合法的游戏行为。请在使用本模组前查阅服务器的相关规定。如果服务器规则严格,请使用 ] 键提高延迟时间。使用本模组的风险由用户自行承担。
CobSwap
CobSwap is a client-side Fabric mod that places cobwebs for you during combat. Hold a sword or axe, left-click a block next to your opponent, and it switches to your cobweb, places it, and switches back to your weapon. It uses normal slot switching and block placement, with an adjustable delay between steps.
No server-side install is needed.
Features
- One-click cobweb placement. Left-click a block while holding a sword or axe, and CobSwap handles the swap, place and swap-back.
- Combat-aware. It only triggers when a living entity (a player or a mob) is within about 3 blocks of the placement spot and the spot is empty. Everywhere else, mining works as normal.
- Normal attacks are untouched. CobSwap only reacts to left-clicks on blocks. Hitting a player or mob works exactly as in vanilla.
- Adjustable delay. The wait between steps defaults to 2 ticks (about 100 ms) and can be set from 0 to 10 ticks. You can change it live in-game, and it is saved to
config/cobswap.json.
- On/off toggle. The mod starts OFF each time you launch the game, so it never fires unexpectedly. This also stops it from placing webs while you mine with a sword.
- Rebindable keys. Every keybind is listed under Options > Controls > Key Binds > CobSwap.
- Action-bar feedback. Toggling and delay changes show a short message above your hotbar.
How it works
When CobSwap is ON, all of these must be true:
- You are holding a sword or axe in your main hand.
- You left-click a block (not an entity).
- The space next to the clicked face is empty.
- A living entity is within about 3 blocks of that space.
- A cobweb is in your hotbar (slots 1-9).
CobSwap then cancels the normal mining action, switches to your cobweb slot, waits for the delay, places the cobweb, waits again, and switches back to your original slot. If any condition fails, the click behaves as vanilla Minecraft would.
Default controls
| Action |
Key |
| Toggle CobSwap on/off |
G |
| Increase delay (+1 tick) |
] |
| Decrease delay (-1 tick) |
[ |
All of these can be rebound in the Controls menu.
Requirements
- Minecraft 1.21.11
- Fabric Loader 0.19.3 or newer
- Fabric API
- Java 21
Installation
- Install Fabric Loader for Minecraft 1.21.11.
- Put Fabric API and the CobSwap jar in your
mods folder.
- Launch with the Fabric profile and check your keys in Controls.
Important notice
CobSwap automates a repeated inventory action in combat. Many multiplayer servers prohibit macros or automation, and some anti-cheat systems flag fast inventory actions even when each one is a normal game action. Check the server's rules before using this mod. If a server is strict, raise the delay with the ] key. You use this mod at your own risk.
评论 0
登录后参与评分
还没有评论,来抢沙发吧