Skip to content

Instantly share code, notes, and snippets.

View Happy2018new's full-sized avatar
🏠
Working from home

Eternal Crystal Happy2018new

🏠
Working from home
  • YingLunTown & DreamLand Development Group
  • Sichuan Province, China
  • 08:30 (UTC +08:00)
View GitHub Profile
@Alemiz112
Alemiz112 / PaletteHashTest.java
Last active April 20, 2025 15:20
Example implementation of Minecraft: Bedrock block state network hash computation
public class PaletteHashTest {
private static final int FNV1_32_INIT = 0x811c9dc5;
private static final int FNV1_PRIME_32 = 0x01000193;
public static void main(String[] args) throws Exception {
NbtMap blockState = NbtMap.builder()
.putString("name", "minecraft:bamboo_hanging_sign")
.putCompound("states", NbtMap.builder()
.putInt("facing_direction", 3)