1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 19:19:56 +00:00

Merge remote-tracking branch 'internecine/master'

This commit is contained in:
Marc Zinnschlag 2014-10-13 19:11:14 +02:00
commit 528dcf761d
4 changed files with 50 additions and 45 deletions

View file

@ -348,7 +348,7 @@ void WeatherManager::transition(float factor)
mResult.mRainFrequency = current.mRainFrequency;
}
void WeatherManager::update(float duration)
void WeatherManager::update(float duration, bool paused)
{
float timePassed = mTimePassed;
mTimePassed = 0;
@ -483,6 +483,8 @@ void WeatherManager::update(float duration)
mRendering->getSkyManager()->secundaDisable();
}
if (!paused)
{
if (mCurrentWeather == "thunderstorm" && mNextWeather == "")
{
if (mThunderFlash > 0)
@ -529,6 +531,8 @@ void WeatherManager::update(float duration)
}
else
mRendering->getSkyManager()->setLightningStrength(0.f);
}
mRendering->setAmbientColour(mResult.mAmbientColor);
mRendering->sunEnable(false);

View file

@ -169,8 +169,9 @@ namespace MWWorld
/**
* Per-frame update
* @param duration
* @param paused
*/
void update(float duration);
void update(float duration, bool paused = false);
void stopSounds(bool stopAll);

View file

@ -1489,7 +1489,7 @@ namespace MWWorld
if (mGoToJail && !paused)
goToJail();
updateWeather(duration);
updateWeather(duration, paused);
if (!paused)
doPhysics (duration);
@ -2666,7 +2666,7 @@ namespace MWWorld
action.execute(ptr);
}
void World::updateWeather(float duration)
void World::updateWeather(float duration, bool paused)
{
if (mPlayer->wasTeleported())
{
@ -2674,7 +2674,7 @@ namespace MWWorld
mWeatherManager->switchToNextWeather(true);
}
mWeatherManager->update(duration);
mWeatherManager->update(duration, paused);
}
struct AddDetectedReference

View file

@ -99,7 +99,7 @@ namespace MWWorld
std::string mStartCell;
void updateWeather(float duration);
void updateWeather(float duration, bool paused = false);
int getDaysPerMonth (int month) const;
void rotateObjectImp (const Ptr& ptr, Ogre::Vector3 rot, bool adjust);