sashakoshka / m4kc

Minecraft 4k: decompiled, translated to C using SDL for graphics and input, and improved upon
78 stars 8 forks source link

Almost completely fix the rendering bugs in the negatives #32

Closed Tempetas closed 1 year ago

Tempetas commented 1 year ago

The issue was being caused by the incorrect usage of integer casts. Basically, a negative float with a value like -1.2 would be turned into -1, while the result needed in our case is -2, which, thankfully, floor() returns.

This pull request also removes the player offset entirely, as its not needed anymore.

The only visual glitch remaining is the minor pixel dithering on the border between the negative and positive coordinates. Screenshot

sashakoshka commented 1 year ago

Absolutely incredible