From df32fe7e02b3030826600fef84c26b82dc2e5c1b Mon Sep 17 00:00:00 2001 From: kervala Date: Sat, 14 Dec 2013 09:18:51 +0100 Subject: [PATCH] Changed: #71 Crash when entering rooms (patch provided by Tierry Anthony, thanks!) --- code/ryzom/client/src/main_loop.cpp | 30 +++++++++++++---------------- 1 file changed, 13 insertions(+), 17 deletions(-) diff --git a/code/ryzom/client/src/main_loop.cpp b/code/ryzom/client/src/main_loop.cpp index 4547ea591..bd5112f99 100644 --- a/code/ryzom/client/src/main_loop.cpp +++ b/code/ryzom/client/src/main_loop.cpp @@ -688,26 +688,22 @@ void updateWeather() } #endif + // FIXME: temporary fix for teleportation crash // Update new sky - if (ContinentMngr.cur() && !ContinentMngr.cur()->Indoor) + if (ContinentMngr.cur() && Driver->getPolygonMode() == UDriver::Filled && Filter3D[FilterSky]) { - if(Driver->getPolygonMode() == UDriver::Filled) + CSky &sky = ContinentMngr.cur()->CurrentSky; + + if (!ContinentMngr.cur()->Indoor && sky.getScene()) { - if (Filter3D[FilterSky]) - { - CSky &sky = ContinentMngr.cur()->CurrentSky; - if (sky.getScene()) - { - s_SkyMode = NewSky; - sky.getScene()->animate(TimeInSec-FirstTimeInSec); - // Setup the sky camera - preRenderNewSky(); - } - else - { - s_SkyMode = OldSky; - } - } + s_SkyMode = NewSky; + sky.getScene()->animate(TimeInSec-FirstTimeInSec); + // Setup the sky camera + preRenderNewSky(); + } + else + { + s_SkyMode = OldSky; } } }