This is a project that carries some element of personal risk and was developed purely as an instrument of masochism. If you are below the age of majority or are an employer looking for interesting personal projects, please leave and pretend you never saw this.
Hi, this is my first Fabric mod. I still suck at Gradle.
It connects PiShock devices to Minecraft, allowing them to react to ingame damage, and has a comprehensive set of options to configure that experience.
- Works in multiplayer, even on non-modded servers
- Vibration/shock threshold
- Vibration-only mode
- Careful limit respecting with multiple layers of failsafe
- Multiple share code support
- Millisecond-precise duration settings
- Queues and combines damage events that occur in quick succession
- Low-latency usage via local serial API (advanced users only; requires PiShock to be connected directly to the computer running Minecraft)
If you are struggling and need to switch it off ASAP, the fastest way is to simply exit the game unceremoniously. On Windows, this is Alt+F4. Test it out before you use it.
There is also an in-game toggle hotkey which defaults to F12. Equally, configure this and check that it is working before you use it.
By default, this mod starts with the actual API calls disabled, with the expectation that you edit the settings to respect your personal limits and then enable it manually.
- Minecraft 1.21 (see the Releases page or other branches for other versions)
- Fabric Loader 0.15.11
- Fabric API
- Cloth Config
- Mod Menu (optional but strongly recommended; gives access to the settings screen)
This approach is recommended for users who are not familiar with modding.
- Download the latest release from the releases page. Make sure you
get the one corresponding to the version of Minecraft you are using. (The
number after the
+
in the version name is the version of Minecraft it supports.) - Download and install Prism Launcher.
- Open Prism Launcher and click "Add Instance".
- Create a new custom instance
- Choose a Minecraft version in the 1.21 series.
- Choose either Fabric or Quilt as the mod loader, at the latest version.
- Click OK.
- Right-click your newly-created instance and click "Edit".
- Go to the "Mods" tab and click "Add file".
- Choose the JAR file you downloaded in step 1.
- Click "Download mods" and select the following mods: (these should all be
close to the top of the list)
- Fabric API
- Cloth Config API
- Mod Menu
- Click "Review and Confirm" and then "OK".
- Click "Launch" to start the game. You can launch the game in future just by double-clicking the instance in Prism Launcher.
- Prepare a Minecraft instance modded with Fabric or Quilt.
- Download the latest release from the releases page.
- Put the downloaded JAR file in your
.minecraft/mods
folder. - Download any missing required mods (see the Requirements section).
- Start the game.
There are several other mods that do similar things to PiShock-Zap. I will compare them and then note some more specific quirks of each.
Feature | PiShock-Zap | PiShockForMc | Shockcraft | Minecraft Shock Collar | Raith's PiShock mod | The original Forge mod |
---|---|---|---|---|---|---|
Minecraft versions | 1.18.2, 1.20.x, 1.21.x | 1.19.x, 1.20.x, 1.21.x | 1.19.3, 1.19.4 | Wide range | 1.19.x, 1.20.x | 1.18.2 |
Author | ScoreUnder | ojaha065 | yanchan09 | Hepno | Raith | DrasticLp |
Mod loader | Fabric | Forge | Fabric | Bukkit | Forge | Forge |
Client-side | ✅ | ✅ | ✅ | ❌ | ❓ | ✅ |
Singleplayer | ✅ | ✅ | ✅ | ❌ | ❓ | ✅ |
Multiplayer | ✅ | ✅ | ✅ | ✅ | ❓ | ✅ |
Works on vanilla servers | ✅ | ✅ | ✅ | ❌ | ❓ | ❌ |
Low-latency local serial API | ✅ | ❌ | ❌ | ❌ | ❓ | ❌ |
Multiple share codes | ✅ | ❌ | ❌ | ❌ | ❓ | ❌ |
Vibration support | ✅ | ✅ | ❌ | ❌ | ❓ | ❌ |
Vibration/shock threshold | ✅ | ❌ | ❌ | ❌ | ❓ | ❌ |
API connectivity checks | ❌ | ✅ | ❌ | ❌ | ❓ | ❌ |
Vibration test button | ❌ | ✅ | ❌ | ❌ | ❓ | ❌ |
In-game quick toggle | Via hotkey | ❌ | Via command | ❌ | ❓ | ❌ |
Damage curves | ✅ | ✅ | ❌ | ❌ | ❓ | ✅ |
Queued/combined damage events | ✅ | ✅ | ❌ | ❌ | ❓ | ❌ |
Separate shock-on-death config | ✅ | ✅ | ❌ | ❌ | ❓ | ✅ |
Millisecond-precise duration | ✅ | ❌ | ❌ | ✅ | ❓ | ❌ |
Configuration method | In-game settings | In-game settings | Slash commands | Configuration file | ❓ | In-game settings |
Configurability | Control-freak | Simple | Basic | Basic | ❓ | Simple |
Known performance issues | 🆗 | 🆗 | 🆗 | ❓ | ||
Known limit-exceeding bugs | 🆗 | 🆗 | 🆗 | 🆗 | ❓ | |
Limit-respecting failsafes | Multi-level | Some | N/A | N/A | ❓ | ❌ |
Source code available | ✅ | ✅ | ✅ | ✅ | ❓ | ❌ |
It has a hardcoded duration of 0.6 seconds for all shocks except the shock on death. It uses a different method of damage detection, which may result in slightly different behaviour in edge cases. I am not sure if it is more or less reliable than PiShock-Zap.
This uses a slightly different method of damage detection, but also different from PiShockForMc. Again, I am not sure which method is more reliable.
You will need to have control over the server to use this mod. It may cause performance issues on the server side due to blocking HTTP requests being made on the main thread.
It zaps the configured person when any player gets damaged, while most other mods zap the configured person when the local player gets damaged. Because of how it is implemented, it can only be configured to zap one person at a time per server.
It is much simpler than PiShock-Zap, which makes it a better starting point for new developers to understand Minecraft and PiShock integration, or to modify it to their needs.
It supports millisecond-precise duration settings, but only on a technicality; the duration is meant to be in seconds, but if you configure a duration higher than 100, it will be interpreted by the PiShock API as milliseconds instead.
The website is no longer available, and as such I cannot compare or link to it.
Not recommended due to known bugs and no clear path to updates.
This was originally distributed as a jar file on the PiShock discord, but has since disappeared. I had a copy lying around and have mirrored it.
It can be used on multiplayer servers, but only if the server has the mod installed. It may cause small client-side stutters when the player is damaged due to performing blocking HTTP requests on the main thread.