A detailed Minecraft-style voxel sandbox built in plain HTML/CSS/JavaScript with Three.js.
- Infinite-ish chunked voxel world streamed around the player
- Deterministic seeded terrain generation
- Multi-layer noise terrain
- Biome selection (Plains, Forest, Desert)
- Caves carved with 3D noise
- Water level and shore blending
- Procedural trees
- Custom voxel meshing
- Per-face culling
- Separate opaque / cutout / translucent layers
- Neighbor-aware rebuild when editing blocks
- Minecraft-like first person gameplay
- Pointer lock mouse look
- WASD movement, sprint, jump
- Gravity and AABB collisions against blocks
- DDA voxel raycast for precise targeting
- Break/place blocks with mouse
- Procedural texture atlas generated at runtime
- Pixel textures for grass, dirt, stone, sand, logs, leaves, planks, glass, water, cobble, bucket
- Nearest-neighbor filtering for crisp voxel style
- Custom decorative block
- Placeable
Wooden Chairblock with non-cubic voxel model (seat, backrest, legs)
- Placeable
- Water bucket + fluid simulation
- Placeable source water from hotbar
- Downward and lateral flow with level decay
- Basic infinite-source behavior (2 adjacent sources over solid support)
- Redstone systems
- Redstone dust power levels (0-15) with propagation and decay
- Repeaters (directional output)
- Comparators (compare/subtract modes with analog output)
- Pistons with extension/retraction and push behavior
- Hard/soft power model through strong and weak signals
- HUD / UX
- Crosshair
- Hotbar (1-9 + scroll selection)
- Selected block label
- Debug panel with FPS, position, biome, target block, chunk queue
- Atmosphere
- Dynamic day/night light cycle
- Fog and sky color transition
- Persistence
- Block edits saved to
localStorageand re-applied on load
- Block edits saved to
index.html: app entry + overlay UIstyle.css: HUD and screen stylingsrc/config.js: global constantssrc/blocks.js: block registry, rendering metadata, face definitionssrc/noise.js: seeded 2D/3D value noise + FBMsrc/atlas.js: procedural texture atlas and tile icon generationsrc/world.js: chunk generation, meshing, streaming, persistence, raycastingsrc/player.js: pointer-lock movement, physics, collisionssrc/main.js: app bootstrap, loop, UI, interaction wiring
You need to serve the folder over HTTP (do not open index.html directly with file://).
python3 -m http.server 8000Then open:
http://localhost:8000
npx serve .WASD: MoveSpace: JumpShift: SprintMouse: Look aroundLeft Click: Break blockRight Click: Place selected blockRight Clickon comparator while holding comparator: Toggle compare/subtract mode1-9orMouse Wheel: Select hotbar blockF3: Toggle debug panelEsc: Unlock cursor
Set a custom world seed via URL query:
http://localhost:8000/?seed=myworld
- This clone focuses on core sandbox loop and terrain pipeline.
- It does not yet implement mobs, crafting, inventory grids, hunger, or multiplayer.