mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/GabsPuNs-MinecraftConsoles.git
synced 2026-06-29 20:36:02 +00:00
Implement isFoggy();
In TU25, isFoggyAt is replaced with isFoggy for add foggy biomes
This commit is contained in:
@@ -2243,19 +2243,6 @@ void GameRenderer::setupFog(int i, float alpha)
|
||||
if (i == 999)
|
||||
{
|
||||
__debugbreak();
|
||||
// 4J TODO
|
||||
/*
|
||||
glFog(GL_FOG_COLOR, getBuffer(0, 0, 0, 1));
|
||||
glFogi(GL_FOG_MODE, GL_LINEAR);
|
||||
glFogf(GL_FOG_START, 0);
|
||||
glFogf(GL_FOG_END, 8);
|
||||
|
||||
if (GLContext.getCapabilities().GL_NV_fog_distance) {
|
||||
glFogi(NVFogDistance.GL_FOG_DISTANCE_MODE_NV, NVFogDistance.GL_EYE_RADIAL_NV);
|
||||
}
|
||||
|
||||
glFogf(GL_FOG_START, 0);
|
||||
*/
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -2346,14 +2333,8 @@ void GameRenderer::setupFog(int i, float alpha)
|
||||
glFogf(GL_FOG_START, distance * 0.25f);
|
||||
glFogf(GL_FOG_END, distance);
|
||||
}
|
||||
/* 4J - removed - TODO investigate
|
||||
if (GLContext.getCapabilities().GL_NV_fog_distance)
|
||||
{
|
||||
glFogi(NVFogDistance.GL_FOG_DISTANCE_MODE_NV, NVFogDistance.GL_EYE_RADIAL_NV);
|
||||
}
|
||||
*/
|
||||
|
||||
if (mc->level->dimension->isFoggyAt(static_cast<int>(player->x), static_cast<int>(player->z)))
|
||||
if (mc->level->getBiome(static_cast<int>(player->x), static_cast<int>(player->z))->isFoggy())
|
||||
{
|
||||
glFogf(GL_FOG_START, distance * 0.05f);
|
||||
glFogf(GL_FOG_END, min(distance, 16 * 16 * .75f) * .5f);
|
||||
|
||||
Reference in New Issue
Block a user