mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-27 03:35:27 +00:00
Simplify new game movie player
This commit is contained in:
parent
6bd0bbb8df
commit
220ab86eca
@ -628,6 +628,9 @@ namespace MWGui
|
|||||||
effectsDx = (viewSize.width - mMinimapBoxBaseRight) - (viewSize.width - mEffectBoxBaseRight);
|
effectsDx = (viewSize.width - mMinimapBoxBaseRight) - (viewSize.width - mEffectBoxBaseRight);
|
||||||
|
|
||||||
mMapVisible = mMinimapBox->getVisible ();
|
mMapVisible = mMinimapBox->getVisible ();
|
||||||
|
if (!mMapVisible)
|
||||||
|
mCellNameBox->setVisible(false);
|
||||||
|
|
||||||
mEffectBox->setPosition((viewSize.width - mEffectBoxBaseRight) - mEffectBox->getWidth() + effectsDx, mEffectBox->getTop());
|
mEffectBox->setPosition((viewSize.width - mEffectBoxBaseRight) - mEffectBox->getWidth() + effectsDx, mEffectBox->getTop());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -298,6 +298,7 @@ namespace MWGui
|
|||||||
delete mCharGen;
|
delete mCharGen;
|
||||||
mCharGen = new CharacterCreation();
|
mCharGen = new CharacterCreation();
|
||||||
mGuiModes.clear();
|
mGuiModes.clear();
|
||||||
|
MWBase::Environment::get().getInputManager()->changeInputMode(false);
|
||||||
mHud->unsetSelectedWeapon();
|
mHud->unsetSelectedWeapon();
|
||||||
mHud->unsetSelectedSpell();
|
mHud->unsetSelectedSpell();
|
||||||
unsetForceHide(GW_ALL);
|
unsetForceHide(GW_ALL);
|
||||||
@ -1412,6 +1413,7 @@ namespace MWGui
|
|||||||
mConsole->resetReference();
|
mConsole->resetReference();
|
||||||
|
|
||||||
mGuiModes.clear();
|
mGuiModes.clear();
|
||||||
|
MWBase::Environment::get().getInputManager()->changeInputMode(false);
|
||||||
updateVisible();
|
updateVisible();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -130,7 +130,7 @@ namespace MWWorld
|
|||||||
: mPlayer (0), mLocalScripts (mStore),
|
: mPlayer (0), mLocalScripts (mStore),
|
||||||
mSky (true), mCells (mStore, mEsm),
|
mSky (true), mCells (mStore, mEsm),
|
||||||
mActivationDistanceOverride (activationDistanceOverride),
|
mActivationDistanceOverride (activationDistanceOverride),
|
||||||
mFallback(fallbackMap), mPlayIntro(0), mTeleportEnabled(true), mLevitationEnabled(true),
|
mFallback(fallbackMap), mTeleportEnabled(true), mLevitationEnabled(true),
|
||||||
mFacedDistance(FLT_MAX), mGodMode(false), mContentFiles (contentFiles),
|
mFacedDistance(FLT_MAX), mGodMode(false), mContentFiles (contentFiles),
|
||||||
mGoToJail(false),
|
mGoToJail(false),
|
||||||
mStartCell (startCell)
|
mStartCell (startCell)
|
||||||
@ -191,9 +191,6 @@ namespace MWWorld
|
|||||||
|
|
||||||
if (!bypass)
|
if (!bypass)
|
||||||
{
|
{
|
||||||
// FIXME: should be set to 1, but the sound manager won't pause newly started sounds
|
|
||||||
mPlayIntro = 2;
|
|
||||||
|
|
||||||
// set new game mark
|
// set new game mark
|
||||||
mGlobalVariables["chargenstate"].setInteger (1);
|
mGlobalVariables["chargenstate"].setInteger (1);
|
||||||
mGlobalVariables["pcrace"].setInteger (3);
|
mGlobalVariables["pcrace"].setInteger (3);
|
||||||
@ -233,6 +230,9 @@ namespace MWWorld
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!bypass)
|
||||||
|
MWBase::Environment::get().getWindowManager()->playVideo(mFallback.getFallbackString("Movies_New_Game"), true);
|
||||||
|
|
||||||
// we don't want old weather to persist on a new game
|
// we don't want old weather to persist on a new game
|
||||||
delete mWeatherManager;
|
delete mWeatherManager;
|
||||||
mWeatherManager = 0;
|
mWeatherManager = 0;
|
||||||
@ -271,7 +271,6 @@ namespace MWWorld
|
|||||||
mGodMode = false;
|
mGodMode = false;
|
||||||
mSky = true;
|
mSky = true;
|
||||||
mTeleportEnabled = true;
|
mTeleportEnabled = true;
|
||||||
mPlayIntro = 0;
|
|
||||||
mFacedDistance = FLT_MAX;
|
mFacedDistance = FLT_MAX;
|
||||||
|
|
||||||
mGlobalVariables.fill (mStore);
|
mGlobalVariables.fill (mStore);
|
||||||
@ -1369,13 +1368,6 @@ namespace MWWorld
|
|||||||
|
|
||||||
void World::update (float duration, bool paused)
|
void World::update (float duration, bool paused)
|
||||||
{
|
{
|
||||||
if (mPlayIntro)
|
|
||||||
{
|
|
||||||
--mPlayIntro;
|
|
||||||
if (mPlayIntro == 0)
|
|
||||||
MWBase::Environment::get().getWindowManager()->playVideo(mFallback.getFallbackString("Movies_New_Game"), true);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mGoToJail && !paused)
|
if (mGoToJail && !paused)
|
||||||
goToJail();
|
goToJail();
|
||||||
|
|
||||||
|
@ -138,8 +138,6 @@ namespace MWWorld
|
|||||||
void loadContentFiles(const Files::Collections& fileCollections,
|
void loadContentFiles(const Files::Collections& fileCollections,
|
||||||
const std::vector<std::string>& content, ContentLoader& contentLoader);
|
const std::vector<std::string>& content, ContentLoader& contentLoader);
|
||||||
|
|
||||||
int mPlayIntro;
|
|
||||||
|
|
||||||
bool mTeleportEnabled;
|
bool mTeleportEnabled;
|
||||||
bool mLevitationEnabled;
|
bool mLevitationEnabled;
|
||||||
bool mGoToJail;
|
bool mGoToJail;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user