mirror of
https://github.com/ZDoom/qzdoom.git
synced 2025-02-26 13:51:09 +00:00
- fixed the compatibility handler of AAmbientSound::Serialize.
SVN r2802 (trunk)
This commit is contained in:
parent
6789b8936c
commit
198c714dad
1 changed files with 3 additions and 33 deletions
|
@ -2005,40 +2005,10 @@ IMPLEMENT_CLASS (AAmbientSound)
|
||||||
void AAmbientSound::Serialize (FArchive &arc)
|
void AAmbientSound::Serialize (FArchive &arc)
|
||||||
{
|
{
|
||||||
Super::Serialize (arc);
|
Super::Serialize (arc);
|
||||||
arc << bActive;
|
arc << bActive << NextCheck;
|
||||||
|
if (SaveVersion < 2798)
|
||||||
if (SaveVersion < 1902)
|
|
||||||
{
|
{
|
||||||
arc << NextCheck;
|
NextCheck += level.maptime;
|
||||||
NextCheck += gametic;
|
|
||||||
if (NextCheck < 0) NextCheck = INT_MAX;
|
|
||||||
}
|
|
||||||
else if (SaveVersion < 2798)
|
|
||||||
{
|
|
||||||
if (arc.IsStoring())
|
|
||||||
{
|
|
||||||
if (NextCheck != INT_MAX)
|
|
||||||
{
|
|
||||||
int checktime = NextCheck - gametic;
|
|
||||||
arc << checktime;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
arc << NextCheck;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
arc << NextCheck;
|
|
||||||
if (NextCheck != INT_MAX)
|
|
||||||
{
|
|
||||||
NextCheck += gametic;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
arc << NextCheck;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue