From: <rly...@us...> - 2010-07-31 20:56:40
|
Revision: 6073 http://planeshift.svn.sourceforge.net/planeshift/?rev=6073&view=rev Author: rlydontknow Date: 2010-07-31 20:56:34 +0000 (Sat, 31 Jul 2010) Log Message: ----------- added PlaneShift.Weather.Enabled, if set to false, all weather messages are ignored todo: add pslaunch checkbox for weather and disable weather effects for low detail levels Modified Paths: -------------- trunk/src/client/modehandler.cpp trunk/src/client/modehandler.h Modified: trunk/src/client/modehandler.cpp =================================================================== --- trunk/src/client/modehandler.cpp 2010-07-31 19:57:30 UTC (rev 6072) +++ trunk/src/client/modehandler.cpp 2010-07-31 20:56:34 UTC (rev 6073) @@ -131,6 +131,8 @@ lightningreset->SetName("lightning reset"); lightningreset->SetColor(csColor(0.0f)); engine->GetVariableList()->Add(lightningreset); + + processWeather = psengine->GetConfig()->GetBool("PlaneShift.Weather.Enabled", true); } ModeHandler::~ModeHandler() @@ -316,7 +318,8 @@ return; case MSGTYPE_WEATHER: - HandleWeatherMessage(me); + if(processWeather) + HandleWeatherMessage(me); return; case MSGTYPE_NEWSECTOR: Modified: trunk/src/client/modehandler.h =================================================================== --- trunk/src/client/modehandler.h 2010-07-31 19:57:30 UTC (rev 6072) +++ trunk/src/client/modehandler.h 2010-07-31 20:56:34 UTC (rev 6073) @@ -183,6 +183,7 @@ WeatherObject* downfall; // Weather object following the player around WeatherObject* fog; // Weather object that is always in effect csPDelArray<WeatherPortal> portals; // Weather for portals out of the sector. + bool processWeather; // determine whether to show weather effects or not void HandleModeMessage(MsgEntry* me); void HandleWeatherMessage(MsgEntry* me); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |