ClassiCube-Client icon indicating copy to clipboard operation
ClassiCube-Client copied to clipboard

Water block rendering not quite right

Open mstefarov opened this issue 11 years ago • 5 comments

Bottom-most water block overlaps with the block below it from certain angles.

mstefarov avatar Mar 07 '14 16:03 mstefarov

Happens with lava too. screenshot_20140308070357

UnknownShadow200 avatar Mar 07 '14 20:03 UnknownShadow200

If you look closely at the top right corner, you can see it slightly overlaps the adjacent glass block on one side, and there is a slight gap on the other side.

screenshot_20140308071724

UnknownShadow200 avatar Mar 07 '14 20:03 UnknownShadow200

@123DMWM Unfortunately, your fix causes problems with transparent blocks..

screenshot_20140313063225 screenshot_20140313063328

UnknownShadow200 avatar Mar 12 '14 19:03 UnknownShadow200

The Texture is generated as 16x16 but the block is 16x15. This'll be a good place to start looking for a solution

Jonty800 avatar Mar 12 '14 21:03 Jonty800

The correct way is to set the LiquidBlock bounds to setBounds(0F, 0F, 0F, 1F, 0.95F, 1F);

screenshot_20140312215245

However this causes a graphical issue with flowing water

screenshot_20140312215309

The extra pixel appears to exist to fix this issue

Jonty800 avatar Mar 12 '14 21:03 Jonty800