Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

Header

Static Badge Static Badge Static Badge

Static Badge Static Badge Static Badge

Terrain development in Minecraft relies on large, deeply nested JSON structures that quickly become difficult to read and maintain. Rhombus introduces powerful abstractions and a comprehensive Python API, making world generation code cleaner, more modular, and significantly faster to develop.

Rhombus is an eDSL delivered as a Python package that allows worldgen developers to comfortably write expressions resembling the abstract syntax trees of density functions for Minecraft while benefiting from Python's forgiving syntax.

This project is pretty similar to misode/gaia-beet, which you might also find useful. Know that I started developing Rhombus before I knew about it, the similarities in concept are quite frightening though. The biggest difference to Misode's gaia-beet is that Rhombus does not see itself as a mere Beet plugin — although we heavily rely on it — but rather as a coherent, mostly separated language and it will be further developed and improved in exactly this sense.

Key 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 docstrings describing behavior, parameters, and usage.
  • Performance Optimization
    Recurring expressions and resource intense operations can be cached automatically.
  • 🗄️ Macro Library
    Growing collection of macros for common patterns and complex operations, reducing boilerplate and improving readability.

Feature List

This list only includes features that are principially not neccessary, but make up the real strengths of Rhombus.

  • Rhombus Preview
    A lightweight local frontend with file-watching for previewing density functions
    • Visualizer (built on deepslate)
      • Supports all major worldgen mods (see Mod Support)
    • File Explorer & Viewer (built on monaco)
    • Spline Visualization
  • Macro Library
    • Math
      • sum, prod
      • Infinity, NaN
      • round, floor, ceil, mod
      • sgn, heaviside, monus, ramp
    • Spline approximations
      • Sampler for any Python function
      • sin, cos, tan, atan, tanh, coth
      • exp (with arbitrary base)
      • smoothstep, normalPDF, normalCDF, erf, logistic
    • Performance optimization
      • evaluate the number of unique nodes of a function
      • automatically cache specific sub functions of a function
      • automatically cache all recurring sub functions of a function
    • Expensive iterative Methods:
      • sqrt
      • sin, cos, tan, exp, ln
      • round, ceil, floor, mod
    • Working with Maps
      • extrude_heightmap
    • Fluent Interface for conditionality
    • Coordinate reconstruction
  • Mod Support
    • More Density Functions
    • Lithostitched
    • Tectonic
    • En-sityFunctions

Impressions

pip install rhombus
from rhombus import *

continent_noise = Noise(-10, [2, 1, 2, 2, 2, 1, 1, 1, 1])
erosion_noise   = Noise(-9, [3.5, 0, 2, 4, 2, 2, 3])

erosion = clamp(noise(erosion_noise, xz_scale=1.3, y_scale=0) - 0.1, min=-1, max=1)

height_map = spline(erosion, [
    (-1,    -1,     0),
    (-0.6,  -0.95,  0),
    (-0.61, -0.6,   0),
    (-0.2,  -0.55,  0),
    (-0.21, -0.2,   0),
    ( 0.05, -0.2,   0),
    ( 0.21,  0.2,   0),
    ( 0.6,   0.3,   0),
    ( 0.61,  0.8,   0),
    ( 1,     0.8,   0)
])

FINAL = maps.extrude_heightmap(height_map, (-1, 0.8), (64, 256))

Preview

Release files for rhombus 0.1.0rc1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rhombus 0.1.0rc1
File Size Uploaded
rhombus-0.1.0rc1.tar.gz 841.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for rhombus 0.1.0rc1
File Interpreter ABI Platform
rhombus-0.1.0rc1-py3-none-any.whl Python 3 none any Details

Total release size: 1.2 MB

Release files / rhombus-0.1.0rc1.tar.gz

Download URL rhombus-0.1.0rc1.tar.gz
Size 841.6 kB
Tags Source
SHA-256 checksum
How to use checksums
4f41e57b2c88ca483de6ee36bc306e1f96f0e6a178495d49c360dd99414f23b2
BLAKE2b-256 checksum
How to use checksums
e10906446ff1f6d85562df1ece8f3433ea28a25ced2e13f75134d4c25460729a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.6

Release files / rhombus-0.1.0rc1-py3-none-any.whl

Download URL rhombus-0.1.0rc1-py3-none-any.whl
Size 364.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
046c5c094384407ca52b9fb54623493141fc5e547868807c9c7024be9dcb4304
BLAKE2b-256 checksum
How to use checksums
6c65b1b1ece162e38d03242360d9792da58206d957e42788444adbb3856518e1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.6
Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page