mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 00:41:55 +00:00
- serialization support for BitArray.
This commit is contained in:
parent
d5c27e6239
commit
1665e340be
2 changed files with 7 additions and 3 deletions
|
@ -302,6 +302,11 @@ FSerializer& Serialize(FSerializer& arc, const char* key, FixedBitArray<size>& v
|
|||
return arc.SerializeMemory(key, value.Storage(), value.StorageSize());
|
||||
}
|
||||
|
||||
inline FSerializer& Serialize(FSerializer& arc, const char* key, BitArray& value, BitArray* def)
|
||||
{
|
||||
return arc.SerializeMemory(key, value.Storage().Data(), value.Storage().Size());
|
||||
}
|
||||
|
||||
template<> FSerializer& Serialize(FSerializer& arc, const char* key, PClass*& clst, PClass** def);
|
||||
template<> FSerializer& Serialize(FSerializer& arc, const char* key, FFont*& font, FFont** def);
|
||||
template<> FSerializer &Serialize(FSerializer &arc, const char *key, Dictionary *&dict, Dictionary **def);
|
||||
|
|
|
@ -267,9 +267,8 @@ void SerializeAutomap(FSerializer& arc)
|
|||
{
|
||||
arc("automapping", automapping)
|
||||
("fullmap", gFullMap)
|
||||
// Only store what's needed. Unfortunately for sprites it is not that easy
|
||||
.SerializeMemory("mappedsectors", show2dsector.Storage().Data(), (numsectors + 7) / 8)
|
||||
.SerializeMemory("mappedwalls", show2dwall.Storage().Data(), (numwalls + 7) / 8)
|
||||
("mappedsectors", show2dsector)
|
||||
("mappedwalls", show2dwall)
|
||||
.EndObject();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue