plsnerfModCheck - Fabric Mod
plsnerfModCheck is a Fabric mod designed to enhance server-client compatibility in Minecraft 1.21.1 by validating client-side mods and ensuring they match server-side requirements. It provides an efficient way for server administrators to manage mod compliance, ensuring all players on the server have the correct setup.
Features
- Client-Server Mod Validation: Automatically verifies the client mod list to ensure compatibility with the server's configuration.
- Custom Download Link for Modpacks: If a client’s mod list does not match the server, they will receive a link to download the correct modpack.
- Multi-Client Support: Allows multiple client modpacks to connect to the same server by validating them against pre-approved configurations.
- Flexible Configuration: The mod generates a
config.json file that can be customized to meet your server's needs, including enabling/disabling features, setting timeouts, and managing multi-client functionality.
- Easy Integration with Modpacks: Supports both single modpack and multi-client configurations, making it highly versatile for modded servers.
- Manifest Support: Server administrators can use a
manifest.json to define required mods for their server, simplifying management. (not implemented now)
Installation and Usage
Server Installation
Download and Setup:
- Download the latest
plsnerfModCheck JAR file from the CurseForge release section.
- Place the downloaded file into your server's
mods folder.
Start the Server:
- Start your Fabric server. This will generate the necessary configuration files in the
config/plsnerfmodcheck folder.
Configuration:
- Open the
config.json file located in config/plsnerfmodcheck.
- Customize the settings to match your server's requirements. For example:
- Enable multi-client support by setting
"multiClient": true.
- Add a custom download link for modpacks using the
downloadLink option.
Client Modlist Validation:
- If you are using multiple modpacks, place their corresponding
modlist.json files into the config/plsnerfmodcheck folder on the server.
- Restart the server to validate and register the modlists.
Testing:
- Have clients connect to the server. If their mod list matches the server’s configuration, they can join. Otherwise, they will receive an error message with the provided download link.
Client Installation
Download and Setup:
- Download the same
plsnerfModCheck JAR file as the server.
- Place the file into your client's
mods folder.
Generate Modlist:
- Start Minecraft. The mod will automatically generate a
modlist.json in the config/plsnerfmodcheck folder.
Share with Server Admin:
- Send the generated
modlist.json to the server administrator so they can validate and add it to the server.
Connect to Server:
- Once the server is configured with your modlist, you can connect without issues. If your mods are incompatible, you will receive a message with a download link to the correct modpack.
Configuration Details
The config.json file is automatically created when the server starts for the first time. Below is an example of the configuration options:
{
"enableMod": true,
"useManifestFile": false,
"multiClient": true,
"TIMEOUT_SECONDS": 5,
"downloadLink": "https://example.com/download-modpack"
}
- enableMod: Enables or disables the mod validation feature.
- useManifestFile: Determines whether to use a
manifest.json for validation.
- multiClient: Enables support for multiple modpack configurations.
- TIMEOUT_SECONDS: Defines the timeout duration for validation.
- downloadLink: URL to redirect players to the correct modpack download if their setup does not match the server.
Use Case Scenarios
Single Modpack Server:
If all players on your server use the same modpack:
- Generate a single
modlist.json from any client.
- Place it in the server’s
config/plsnerfmodcheck folder.
- Enable validation to ensure all clients have the same mod setup.
Multi-Client Support:
For servers that support multiple modpacks:
- Collect
modlist.json files from all supported client modpacks.
- Add them to the
config/plsnerfmodcheck folder on the server.
- Enable
"multiClient": true in the configuration file.
- Players using any of the approved modpacks will be able to connect.
Error Handling
If a client’s modlist does not match the server’s configuration, they will receive an error message:
Your mod list does not match the server's requirements.
Download the correct modpack here: https://example.com/download-modpack
plsnerfModCheck is designed to simplify modpack management and enhance compatibility between clients and servers. With its robust configuration options and multi-client support, it’s an essential tool for any modded Minecraft server.