RandomPatches is a Forge and Fabric mod that can aid with connection issues on modded servers, especially where the connection may be unstable such as on mobile data.
For instance, RandomPatches enables you to configure the conditions for Connection Timeouts and Packet Size Limits which in many cases allows for a much more stable connection.
Installing RandomPatches
The steps below will guide you through installing RandomPatches on both your Client and Server.
Installing RandomPatches on your Client
- Download RandomPatches for either Forge or Fabric.
- Refer to our guides on Installing Forge Mods on Your PC or Installing Fabric Mods on Your PC.
Installing RandomPatches on your Server
- Download RandomPatches for either Forge or Fabric.
- Refer to our guides on Installing Mods on Your Forge Server or Installing Mods on Your Fabric Server.
- Once installed, Start your server to generate the config files.
Configuring RandomPatches
By default, RandomPatches will be pre-configured with more optimised connection settings than Vanilla Minecraft. However, there are many other settings you can configure to your liking.
Accessing the Configuration File on your Server
- Stop your server.
- Access your server’s FTP Directory.
- Navigate to
config
and click Edit next torandompatches.toml
.
Now that you have access to the configuration file, you can proceed to the next section of this article.
Modifying the Configuration File to Mitigate Connection Issues
There are numerous options within RandomPatches that can help to resolve any connection issues you are facing. The following steps will walk you through modifying the config file to improve your connection.
Configuring [connection_timeouts]
Navigate to the [connection_timeouts]
section of the config file. There are three important options in this section, shown below:
- read_timeout_seconds determines how long the server will wait after receiving no response while the player is connecting. Higher is better on unreliable connections (mobile data).
- login_timeout_ticks determines how long the server will wait for a player to log in. Higher is better on slower connections.
- keep_alive_timeout_seconds determines how long the server waits for a player to return a KeepAlive packet before disconnecting them. Higher is better on slower connections.
Adjust these values to your liking and hit Save at the top of the page.
Configuring [packet_size_limits]
These options are less important to resolving connection issues than the above settings, however, in some cases, they can prove essential.
Simply navigate to the [packet_size_limits]
section of the config file to begin adjusting these settings.
- max_compressed_packet_size determines the largest packet that can be sent to or from the server. Some large datapack’s may prevent the player from connecting if this is set too low.
- max_nbt_compound_tag_packet_size determines the maximum packet size of an NBT compound tag packet. Raising this value can help prevent players from being disconnected.
- max_client_custom_payload_packet_size determines the maximum custom payload packet size. Adjusting this is much more relevant to large modded servers. Raising the value may help in preventing disconnects.
Adjust these values to your liking and click Save at the top of the page.
Other RandomPatches Settings
There are many other settings that can be adjusted (and further fixes pre-included) in RandomPatches which are not relevant to this article.
You can find a full list of these on the RandomPatches GitHub.
If you require any further assistance, please contact our support at: https://shockbyte.com/billing/submitticket.php