GravityEngine
What if gravity didn't always pull you downward?
Imagine walking along walls, hanging upside down from ceilings, or standing on the surface of a tiny planet, with the direction of "down" constantly changing beneath your feet.
GravityEngine is a foundational Minecraft mod that provides arbitrary-direction gravity, gravity-aware movement and collision handling, and independent body orientation control.
Its goal is to break free from Minecraft's traditional vertical gravity system and provide a unified, reusable framework for other mods to build upon.
Please note: GravityEngine is primarily a library and framework mod. It does not add planets, gravity generators, or world generation features on its own.
Features
Arbitrary-Direction Gravity
In vanilla Minecraft, gravity always points downward along the world's Y-axis. GravityEngine instead represents gravity as a vector with both direction and magnitude.
This allows gravity to act in virtually any direction, rather than being restricted to the six cardinal directions.
The mod provides a composable gravity field system, allowing multiple gravity sources to interact through different combination rules, including overrides and additive effects.
With GravityEngine, other mods can implement features such as:
- Walking on walls, ceilings, and inclined surfaces;
- Experiencing gravity that points toward the center of a spherical planet, allowing players to walk around its surface;
- Creating localized gravity zones that alter the direction and strength of gravity;
- Simulating weightlessness or environments influenced by multiple gravity fields.
The actual gravity sources, their behavior, and their areas of influence are defined by the mods that use GravityEngine.
Movement and Collision
Changing gravity involves much more than simply rotating the player's model.
Many of Minecraft's movement and collision mechanics assume that the world's Y-axis is always vertical. This includes ground detection, jumping, falling, and bounding-box calculations.
GravityEngine introduces gravity-aware movement and collision handling, allowing entities to move, jump, fall, and interact with surfaces within different gravity reference frames.
Physical collision geometry and visual orientation are handled separately, helping prevent inconsistencies that would otherwise arise from simply rotating an entity's model.
Body Orientation and Flight
In addition to gravity control, GravityEngine introduces an independent body orientation system.
An entity's body orientation does not have to remain aligned with its gravity direction. Camera orientation, movement direction, and collision orientation can be handled independently.
The mod also includes body roll control for Elytra flight, allowing for more flexible flight orientations beyond vanilla Minecraft's limitations.
These systems are designed to operate independently of gravity fields, providing a foundation for more advanced flight mechanics and custom entity movement in the future.
Mod Integration and API
GravityEngine aims to eliminate the need for every mod introducing unconventional gravity to reinvent movement and collision mechanics from scratch.
To achieve this, it exposes APIs for gravity field registration, publication, sampling, and querying entity gravity states.
Developers can define their own gravity sources, areas of influence, and field parameters while keeping gameplay-specific logic separate from the underlying gravity simulation.
For example, a planetary mod could handle planet generation, gravity source placement, and gravity field boundaries, while GravityEngine handles gravity calculations and their integration with entity movement.
This separation allows developers to focus on creating new gameplay experiences rather than rebuilding the underlying physics-related systems.
Compatibility and Development Status
GravityEngine is currently under active development.
The primary development target is Minecraft 1.21.1 with NeoForge. Support for additional Minecraft versions and mod loaders is being worked on, but these versions may not yet offer the same level of functionality.
Because arbitrary-direction gravity affects entity movement, collision detection, camera behavior, body orientation, and client-server synchronization, compatibility issues may arise with mods that modify these systems.
In particular, mods introducing custom movement mechanics, flight systems, or entity collision behavior are not guaranteed to be fully compatible.
No stable release is available yet. Actual functionality and compatibility may vary between versions and development builds.
Gravity doesn't have to point down.

