fangorn/huorn-minecraft
public
ref:692aaa6c0b2195f8e40c1a67aeac431884f893fc
Fix multi-block UV mapping: correct column assignment per facing direction
Root cause: getSubRegion() assigned blockCol left-to-right in world
coordinates, then the renderer flipped U per-block. This caused each
block to independently mirror its sub-region, scrambling the order
(showed columns as 2,3,1 instead of 1,2,3).
Fix: getSubRegion() now assigns blockCol based on the VIEWER's
perspective for each facing direction:
- NORTH: highest X = viewer's left = blockCol 0 (u starts at 0)
- SOUTH: lowest X = viewer's left = blockCol 0
- EAST: highest Z = viewer's left = blockCol 0
- WEST: lowest Z = viewer's left = blockCol 0
The renderer vertex mapping stays the same for both single and
multi-block (x0 gets u1, x1 gets u0) because the directional
logic is now entirely in getSubRegion.
46 GameTests + 52 Rust tests + visual test, all passing.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
SHA:
692aaa6c0b2195f8e40c1a67aeac431884f893fc
Author:
Cole Christensen <cole.christensen@macmillan.com>
Date:
2026-03-20 14:27
Parents:
2741a8f
2 files changed
+29
-13
| Type | ||
|---|---|---|
|
|
common/src/main/java/io/fangorn/alacrittymc/block/ScreenGroup.java | +25 −12 |
|
||