Back to mods
Mouse Lock project artwork

Modrinth · Minecraft mod

Mouse Lock

Toggle mouse locking to assist you with repetitive tasks where you need to go in a straight line, such as farming, planting crops when already aligned to an angle

Choose a version Pick your version below, then grab the matching file.

Quick answer

Which Mouse Lock release should I use?

Updated 9 days ago
Latest stable file 1.0.0
Game version 1.20.1
Loader Fabric

Mouse Lock 1.0.0 targets 1.20.1 with Fabric. It must be installed on the client. Do not install it on the dedicated server. All 2 required mods have matching files.

Where it goes

Is Mouse Lock required on the client, server, or both?

It must be installed on the client. Do not install it on the dedicated server.

Client Required
Dedicated server Not supported
Loader for this release Fabric
Required install it here Optional supported, not mandatory Not supported do not install here Source doesn’t say do not assume

This file is marked client-only.

What else does Mouse Lock 1.0.0 need?

1.0.0. Change the file and its required mods may change too.

All 2 required mods have matching files

Install Fabric API, Forge Config API Port first. We found matching files for this game-version and loader setup. 2 come through another mod in the chain.

2 listed on this file 2 pulled in by those mods
Fabric API Needed by Mouse Lock 1.0.0
required
Matching file found Matched file: 0.92.12+1.20.1
Forge Config API Port Needed by Mouse Lock 1.0.0
required
Matching file found Matched file: v8.0.3-1.20.1-Fabric
Forge Config Screens Needed by Forge Config API Port
pulled in
Matching file found Matched file: v8.0.2-1.20.1-Fabric
Mod Menu Needed by Forge Config Screens
pulled in
Matching file found Matched file: 7.2.2

2 extra mods were pulled in by other dependencies. Indented rows show who needs each one. We only count dependency files that match this setup. A file for another loader does not fill the gap.

Before you install it

Add Mouse Lock without breaking your instance.

Built for Mouse Lock 1.0.0. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use 1.0.0. It targets 1.20.1 with Fabric; another release may have different loader, side or dependency requirements.

  2. 02

    Bring the mods it needs

    Install Fabric API, Forge Config API Port first. We found matching files for this game-version and loader setup. 2 come through another mod in the chain.

  3. 03

    Put it on the correct side

    It must be installed on the client. Do not install it on the dedicated server.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside 1.0.0. It opens that exact file at the source.

About this project

What does Mouse Lock add?

Mouse Lock

This mod adds one single useful feature - locking your player's head rotation, blocking mouse movement inputs when told so.
This is often used for low-interaction repetitive tasks where you need to go in a straight line, having set up the right angle in advance. The main expected usecase is different forms of farming or planting crops, but you can come up with new ways.

Breaking crops with a fixed angle

Using the Feature

To turn the feature on or off, you can use a keybind or a command.

With a Keybind

First of all, set a keybind of your choosing (not set by default), and then just press it when you need to lock your angle:

Keybind

With a Command

You can use /mouselock to lock or unlock the angle. It mostly exists for cases where you would need to trigger it with an another mod.

Toggle Command

Config/Settings

You can configrure the mod with /mouselock settings command or by finding the mod in the mod list and clicking the settings button.

"Mouse Locked" text overlay lets you change:

  • It's size and position
  • Whether it should lift up when hearts are visible
  • Whether mouse lock should reset when leaving or changing worlds.

Config

Usage on servers

The mod just does the same thing as if you didn't move your mouse, which is quite possible, so it's should generally not cause issues, but, of course, it's your responsibility to be aware of a server's rules.

Versions

The mod supports a lot of different versions. Most are backported, and such don't get active support - only the up-to date version does.

One more useful note is that the developer is not actively checking github issues (since they can't send notifications in any way), so those may get ignored even for months. Maybe there will be a discord server later to contact the dev easier.

You can still suggest useful changes or ideas for new features though (maybe for a separate mod), even on the issue tracker.
Hope this mod helps someone :D

Project description from Modrinth.

Pick your setup

Mouse Lock by Minecraft version and loader

Choose the version and loader you play, then open the matching release.

39 available setups

Showing the newest 12 of 20 game versions. Older files are in the list below.

Check the dependencies, then try the file in a copied instance before changing a world you care about.

Recent files

Mouse Lock versions and loaders

28 of 28 releases match

Looking for an older file? The official Modrinth project page is in Resources.