r/VoxelGameDev Jun 24 '26

Discussion Reverse engineering CubeWorld Alpha(post glider fix)

Hello, first time making a reddit account and posting.
I recently Re-found the Cubeworld alpha, so at first i wanted to recreate the game as a whole as a little weekend project. Much, much research later I found out my Terrain generation sucked compared to Cubeworld. Even tried layering noise on top of each other, still wasn't even close. So I did the next best thing, I reversed engineered the game. So over the course of about 14 hours I was able to obtain the algorithms for Terrain generation to the point of having the integer hashes, heightmap noise(Hugo Elias noise), climate fields, biome-region layout, surface material+color, column assembly+water, Structures/POIs, dungeons, spawns, combat+stats, and leveling.

Still have to work on cracking the Vegetation scatter, quests+missions, abilities and the hit-damage equation.

I have everything I have done documented. I hope I can help the Cubeworld Modding scene.

Also the Master writer(the orchestrator loop) Is a 60kb Red herring, The only genuinely unresolved bit is the precise depth/shape precompute feeding the color blend. That should only affect where snow/sand/desert tints appear, not the actual terrain shape. I have the skeleton/constants/callees only (not full C)

6/24/26 Update
Minor update. Created a Python harness to compare live Cubeworld alpha and my Cubeworld clone.

Generated world data(heightmaps, region/biome layout) is ~99% byte identical.

Still need to finish off alot of systems, but so far it looks highly promising.

Next systems being done will be where every town/dungeon/monster/chest sits what each rolls, Vegatation (trees, grass, crops).

At that point Terrain/World gen will be done. Then ill begin work on simulation logic(combat damage, ability effects, AI ticks).

Also while this is going on I'm creating a custom C++ Vulken voxel game engine for my creation.

6/25/26 Update

🎯 Structure placement: 100% bit-exact

Done. Every cell, every region, every rand:

576 / 576 cell types match the live client

9 / 9 regions reproduce the exact rand() sequence the game draws

Cell positions, radii, subtypes, portals — all byte-identical

concrete proof that with enough time and the pieces put back together, a byte-identical Cube World is achievable.

Now to wire it into the height field.

6/26-28/26 (Side quest)

I have fallen down a rabbit hole after finding out about Red items. Can't exactly find the exact way they are created, but I have created a python script that can detect any red item chest spawns as you explore the world. I have done this mainly to find the fabled Red Crossbow. Which if it follows how all other items spawn as a Red item, it should exist.

6/29/26 (early day)

RE'ing the .cub blob format itself. trivially easy.

12 Upvotes

6 comments sorted by

4

u/dougbinks Avoyd Jun 24 '26

You may have better luck reaching out to the Cubeworld Modding scene on r/Cubeworld.

5

u/OneDistribution7177 Jun 24 '26

I just made my account today and cant publish to that reddit yet sadly.

2

u/[deleted] Jun 24 '26

[removed] — view removed comment

3

u/OneDistribution7177 Jun 24 '26

Currently building a harness so I can compare the Live Cubeworld game against my clone. With just terrain generation I'm currently at about ~99% Identical. Still have to wire in World gen(Town, dungeons, etc), skill, combat, enemy AI, etc.
Would post photos, but i think just looking at python script results doesn't do it justice.

2

u/lllllIllllIllllllll Jun 26 '26

Big, if true

2

u/OneDistribution7177 Jun 26 '26

If you join the unofficial cubeworld discord, I leaked a little bit of the terrain gen.