summaryrefslogtreecommitdiff
path: root/indra/newview/llworld.cpp
diff options
context:
space:
mode:
authorMike Antipov <mantipov@productengine.com>2010-05-27 11:02:59 +0300
committerMike Antipov <mantipov@productengine.com>2010-05-27 11:02:59 +0300
commit990e31bb692b62e05f6065b04207acb8ca50cce4 (patch)
tree8bb88d17e763d1a0be37f3c3ff1056f5306a4e77 /indra/newview/llworld.cpp
parent46de549bfba0b95b068b617026e095404ccff2f6 (diff)
parentf33fdbf0ef25c485bdd09faaf1177d2b2b1a7694 (diff)
Merge from default branch.
Incoming changes in (924d091c166c) moved SidebarCameraMovement logic out of special widget to camera setup code are reset changes in (380b2422b864) EXT-7434 FIX Worldview rect wasn't updated when "SidebarCameraMovement" variable But seems bug is not reproduced. --HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llworld.cpp')
-rw-r--r--indra/newview/llworld.cpp36
1 files changed, 31 insertions, 5 deletions
diff --git a/indra/newview/llworld.cpp b/indra/newview/llworld.cpp
index 58b9f5ce18..f30567f481 100644
--- a/indra/newview/llworld.cpp
+++ b/indra/newview/llworld.cpp
@@ -91,7 +91,8 @@ LLWorld::LLWorld() :
mLastPacketsIn(0),
mLastPacketsOut(0),
mLastPacketsLost(0),
- mSpaceTimeUSec(0)
+ mSpaceTimeUSec(0),
+ mClassicCloudsEnabled(TRUE)
{
for (S32 i = 0; i < 8; i++)
{
@@ -662,16 +663,41 @@ void LLWorld::updateClouds(const F32 dt)
static LLFastTimer::DeclareTimer ftm("World Clouds");
LLFastTimer t(ftm);
- if (gSavedSettings.getBOOL("FreezeTime") ||
- !gSavedSettings.getBOOL("SkyUseClassicClouds"))
+ if ( gSavedSettings.getBOOL("FreezeTime") )
{
// don't move clouds in snapshot mode
return;
}
+
+ if (
+ mClassicCloudsEnabled !=
+ gSavedSettings.getBOOL("SkyUseClassicClouds") )
+ {
+ // The classic cloud toggle has been flipped
+ // gotta update all of the cloud layers
+ mClassicCloudsEnabled =
+ gSavedSettings.getBOOL("SkyUseClassicClouds");
+
+ if ( !mClassicCloudsEnabled && mActiveRegionList.size() )
+ {
+ // We've transitioned to having classic clouds disabled
+ // reset all cloud layers.
+ for (
+ region_list_t::iterator iter = mActiveRegionList.begin();
+ iter != mActiveRegionList.end();
+ ++iter)
+ {
+ LLViewerRegion* regionp = *iter;
+ regionp->mCloudLayer.reset();
+ }
+
+ return;
+ }
+ }
+ else if ( !mClassicCloudsEnabled ) return;
+
if (mActiveRegionList.size())
{
- // Update all the cloud puff positions, and timer based stuff
- // such as death decay
for (region_list_t::iterator iter = mActiveRegionList.begin();
iter != mActiveRegionList.end(); ++iter)
{