From 804a7875a2018f3d8cb3fbe917c11ecc1666d25a Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 2 Dec 2012 18:02:04 +0200 Subject: Smooth day-night transitions --- src/game.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/game.cpp') diff --git a/src/game.cpp b/src/game.cpp index fc780a808..5c3805c3b 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -2505,8 +2505,7 @@ void the_game( Calculate general brightness */ u32 daynight_ratio = client.getEnv().getDayNightRatio(); - float time_brightness = (float)decode_light( - (daynight_ratio * LIGHT_SUN) / 1000) / 255.0; + float time_brightness = decode_light_f((float)daynight_ratio/1000.0); float direct_brightness = 0; bool sunlight_seen = false; if(g_settings->getBool("free_move")){ -- cgit v1.2.3