ko4life-net / ko

Open source development of the game Knight Online. This is a reversed engineered old version of the game aiming to replicate the nostalgic experience we all once had <3
https://github.com/ko4life-net/ko
MIT License
55 stars 22 forks source link

Moon and Sun textures are broken at a specific angle #167

Closed stevewgr closed 2 years ago

stevewgr commented 2 years ago

Description

When the Sun or Moon is at a specific angle, the texture displays as white.

The bug introduced from the following PR where it updates device render states: https://github.com/ko4life-net/ko/pull/159

Reverting this change fixes the issue, but we need to find a proper fix for the sky. I think it might be collision of render states or some sort.

Screenshots

image

To Reproduce

Change the sun angle by setting different game time.

stevewgr commented 2 years ago

@xGuTeK, since you worked on this, do you want to check this?

stevewgr commented 2 years ago

Assigning @xGuTeK for the record, since he is working on it.