Skip to content

Instantly share code, notes, and snippets.

@XI64
XI64 / worldoverview.md
Last active December 14, 2023 10:45
Minecraft World Generation Overview by Telepathic Grunt

//World Generation gist written by Telepathic Grunt.

So when minecraft goes to make a chunk, it has a certain order to making the world.

  • Biome Provider
  • ChunkGenerator
  • SurfaceBuilder
  • Carvers
  • Structures/Features Generation Stages
@XI64
XI64 / modInverses.cpp
Last active July 26, 2021 12:40
speedy mod inverses for 2**48
#include <iostream>
const uint64_t MASK = 0xffffffffffffL;
//Credits : Matthew Bolan for the following Function
static inline uint64_t modInverse(uint64_t a,uint64_t k){
uint64_t x = (((a << 2) ^ (a << 1)) & 8) ^ a;
x += x - a * x * x;