Skip to content

Introduction

Density functions are Minecraft's way to describe, how terrain should look at a certain point. Starting with 1.18.2, they are data driven, which means that terrain can be modified through a datapack, without the need to know how to program in Java.

However, like many other things in datapacks, writing these is difficult due to the incomprehensible source format and the lack of good development environments. In addition, the difficulty of density functions goes beyond mere development know-how and also requires a high degree of mathematical background knowledge and creativity — similar to the development of shaders.

Rhombus [ˈʁɔmbʊs] is a tool that facilitates some of these aspects, primarily designed to speed up the work process when you already know what you are doing.

Beet Interoperability

Rhombus is built on the Python-based datapack toolkit Beet. File handling and the integrated developing tools use it, but you are not required to use the Beet pipeline itself for your projects.

So ... What are the keywords?

Main Advantages

  • 📦 Object-oriented Design
    Full use of Python’s object model for composing, reusing, and structuring density functions.
  • 📝 Native Comments
    Since Python code is in use, comments work naturally without any custom syntax.
  • 📖 Integrated Documentation
    Functions and classes provide detailed docstrings describing behavior, parameters, and usage.
  • 🗄️ Macro Library
    Collection of macros simplifies various common applications.
  • Efficient Worldgen Performance
    Density expressions are transpiled into as few files as possible, reducing overhead during chunk generation.

Quality Assurance

  • 🛠️ Generous Modding-API
    Classes can be used to derive support for any features from mods.
  • ⚙️ High Stability
    As long as the format of the density function definition remains unchanged in new versions, the generated data will work in all versions of Minecraft.

Installation

Rhombus is available on the Python Package Index. Alternatively, you can install it via git:

pip install rhombus
or
pip install git+https://github.com/annhilati/rhombus.git

uv pip install rhombus
or
uv pip install git+https://github.com/annhilati/rhombus.git