mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-28 17:39:42 +00:00
Drop support for save game format 1
This commit is contained in:
parent
102d2c4b43
commit
521cff08f8
3 changed files with 20 additions and 32 deletions
|
@ -898,36 +898,27 @@ namespace MWWorld
|
|||
{
|
||||
if (ESM::REC_WTHR == type)
|
||||
{
|
||||
if (reader.getFormatVersion() <= ESM::MaxOldWeatherFormatVersion)
|
||||
ESM::WeatherState state;
|
||||
state.load(reader);
|
||||
|
||||
std::swap(mCurrentRegion, state.mCurrentRegion);
|
||||
mTimePassed = state.mTimePassed;
|
||||
mFastForward = state.mFastForward;
|
||||
mWeatherUpdateTime = state.mWeatherUpdateTime;
|
||||
mTransitionFactor = state.mTransitionFactor;
|
||||
mCurrentWeather = state.mCurrentWeather;
|
||||
mNextWeather = state.mNextWeather;
|
||||
mQueuedWeather = state.mQueuedWeather;
|
||||
|
||||
mRegions.clear();
|
||||
importRegions();
|
||||
|
||||
for (auto it = state.mRegions.begin(); it != state.mRegions.end(); ++it)
|
||||
{
|
||||
// Weather state isn't really all that important, so to preserve older save games, we'll just discard
|
||||
// the older weather records, rather than fail to handle the record.
|
||||
reader.skipRecord();
|
||||
}
|
||||
else
|
||||
{
|
||||
ESM::WeatherState state;
|
||||
state.load(reader);
|
||||
|
||||
std::swap(mCurrentRegion, state.mCurrentRegion);
|
||||
mTimePassed = state.mTimePassed;
|
||||
mFastForward = state.mFastForward;
|
||||
mWeatherUpdateTime = state.mWeatherUpdateTime;
|
||||
mTransitionFactor = state.mTransitionFactor;
|
||||
mCurrentWeather = state.mCurrentWeather;
|
||||
mNextWeather = state.mNextWeather;
|
||||
mQueuedWeather = state.mQueuedWeather;
|
||||
|
||||
mRegions.clear();
|
||||
importRegions();
|
||||
|
||||
for (auto it = state.mRegions.begin(); it != state.mRegions.end(); ++it)
|
||||
auto found = mRegions.find(it->first);
|
||||
if (found != mRegions.end())
|
||||
{
|
||||
auto found = mRegions.find(it->first);
|
||||
if (found != mRegions.end())
|
||||
{
|
||||
found->second = RegionWeather(it->second);
|
||||
}
|
||||
found->second = RegionWeather(it->second);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -49,8 +49,6 @@ namespace ESM
|
|||
esm.getHNOT(mTalkedTo, "TALK");
|
||||
esm.getHNOT(mAlarmed, "ALRM");
|
||||
esm.getHNOT(mAttacked, "ATKD");
|
||||
if (esm.isNextSub("ATCK"))
|
||||
esm.skipHSub(); // attackingOrSpell, no longer used
|
||||
esm.getHNOT(mKnockdown, "KNCK");
|
||||
esm.getHNOT(mKnockdownOneFrame, "KNC1");
|
||||
esm.getHNOT(mKnockdownOverOneFrame, "KNCO");
|
||||
|
|
|
@ -9,7 +9,6 @@ namespace ESM
|
|||
|
||||
inline constexpr FormatVersion DefaultFormatVersion = 0;
|
||||
inline constexpr FormatVersion CurrentContentFormatVersion = 1;
|
||||
inline constexpr FormatVersion MaxOldWeatherFormatVersion = 1;
|
||||
inline constexpr FormatVersion MaxOldDeathAnimationFormatVersion = 2;
|
||||
inline constexpr FormatVersion MaxOldFogOfWarFormatVersion = 6;
|
||||
inline constexpr FormatVersion MaxUnoptimizedCharacterDataFormatVersion = 7;
|
||||
|
@ -28,7 +27,7 @@ namespace ESM
|
|||
inline constexpr FormatVersion MaxActiveSpellSlotIndexFormatVersion = 27;
|
||||
inline constexpr FormatVersion CurrentSaveGameFormatVersion = 29;
|
||||
|
||||
inline constexpr FormatVersion MinSupportedSaveGameFormatVersion = 1;
|
||||
inline constexpr FormatVersion MinSupportedSaveGameFormatVersion = 2;
|
||||
inline constexpr FormatVersion OpenMW0_48SaveGameFormatVersion = 21;
|
||||
inline constexpr FormatVersion OpenMW0_49SaveGameFormatVersion = CurrentSaveGameFormatVersion;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue