Update serialization to BYTE from WORD for older save games.

This commit is contained in:
MajorCooke 2015-12-15 07:19:41 -06:00 committed by Randy Heit
parent b09a81126f
commit 6478b98eea
1 changed files with 6 additions and 0 deletions

View File

@ -3043,6 +3043,12 @@ void player_t::Serialize (FArchive &arc)
WeaponState = ((cheats >> 14) & 1) | ((cheats & (0x37 << 24)) >> (24 - 1));
cheats &= ~((1 << 14) | (0x37 << 24));
}
if (SaveVersion < 4526)
{
BYTE oldWeaponState;
arc << oldWeaponState;
WeaponState = oldWeaponState;
}
else
{
arc << WeaponState;